//===----------------------------------------------------------------------===//
//
// This source file is part of the Soto for AWS open source project
//
// Copyright (c) 2017-2024 the Soto project authors
// Licensed under Apache License v2.0
//
// See LICENSE.txt for license information
// See CONTRIBUTORS.txt for the list of Soto project authors
//
// SPDX-License-Identifier: Apache-2.0
//
//===----------------------------------------------------------------------===//

// THIS FILE IS AUTOMATICALLY GENERATED by https://github.com/soto-project/soto-codegenerator.
// DO NOT EDIT.

#if canImport(FoundationEssentials)
import FoundationEssentials
#else
import Foundation
#endif
@_spi(SotoInternal) import SotoCore

extension APIGateway {
    // MARK: Enums

    public enum AccessAssociationSourceType: String, CustomStringConvertible, Codable, Sendable, CodingKeyRepresentable {
        case vpce = "VPCE"
        public var description: String { return self.rawValue }
    }

    public enum ApiKeySourceType: String, CustomStringConvertible, Codable, Sendable, CodingKeyRepresentable {
        case authorizer = "AUTHORIZER"
        case header = "HEADER"
        public var description: String { return self.rawValue }
    }

    public enum ApiKeysFormat: String, CustomStringConvertible, Codable, Sendable, CodingKeyRepresentable {
        case csv = "csv"
        public var description: String { return self.rawValue }
    }

    public enum AuthorizerType: String, CustomStringConvertible, Codable, Sendable, CodingKeyRepresentable {
        case cognitoUserPools = "COGNITO_USER_POOLS"
        case request = "REQUEST"
        case token = "TOKEN"
        public var description: String { return self.rawValue }
    }

    public enum CacheClusterSize: String, CustomStringConvertible, Codable, Sendable, CodingKeyRepresentable {
        case size0Point5Gb = "0.5"
        case size118Gb = "118"
        case size13Point5Gb = "13.5"
        case size1Point6Gb = "1.6"
        case size237Gb = "237"
        case size28Point4Gb = "28.4"
        case size58Point2Gb = "58.2"
        case size6Point1Gb = "6.1"
        public var description: String { return self.rawValue }
    }

    public enum CacheClusterStatus: String, CustomStringConvertible, Codable, Sendable, CodingKeyRepresentable {
        case available = "AVAILABLE"
        case createInProgress = "CREATE_IN_PROGRESS"
        case deleteInProgress = "DELETE_IN_PROGRESS"
        case flushInProgress = "FLUSH_IN_PROGRESS"
        case notAvailable = "NOT_AVAILABLE"
        public var description: String { return self.rawValue }
    }

    public enum ConnectionType: String, CustomStringConvertible, Codable, Sendable, CodingKeyRepresentable {
        case internet = "INTERNET"
        case vpcLink = "VPC_LINK"
        public var description: String { return self.rawValue }
    }

    public enum ContentHandlingStrategy: String, CustomStringConvertible, Codable, Sendable, CodingKeyRepresentable {
        case convertToBinary = "CONVERT_TO_BINARY"
        case convertToText = "CONVERT_TO_TEXT"
        public var description: String { return self.rawValue }
    }

    public enum DocumentationPartType: String, CustomStringConvertible, Codable, Sendable, CodingKeyRepresentable {
        case api = "API"
        case authorizer = "AUTHORIZER"
        case method = "METHOD"
        case model = "MODEL"
        case pathParameter = "PATH_PARAMETER"
        case queryParameter = "QUERY_PARAMETER"
        case requestBody = "REQUEST_BODY"
        case requestHeader = "REQUEST_HEADER"
        case resource = "RESOURCE"
        case response = "RESPONSE"
        case responseBody = "RESPONSE_BODY"
        case responseHeader = "RESPONSE_HEADER"
        public var description: String { return self.rawValue }
    }

    public enum DomainNameStatus: String, CustomStringConvertible, Codable, Sendable, CodingKeyRepresentable {
        case available = "AVAILABLE"
        case pending = "PENDING"
        case pendingCertificateReimport = "PENDING_CERTIFICATE_REIMPORT"
        case pendingOwnershipVerification = "PENDING_OWNERSHIP_VERIFICATION"
        case updating = "UPDATING"
        public var description: String { return self.rawValue }
    }

    public enum EndpointType: String, CustomStringConvertible, Codable, Sendable, CodingKeyRepresentable {
        case `private` = "PRIVATE"
        case edge = "EDGE"
        case regional = "REGIONAL"
        public var description: String { return self.rawValue }
    }

    public enum GatewayResponseType: String, CustomStringConvertible, Codable, Sendable, CodingKeyRepresentable {
        case accessDenied = "ACCESS_DENIED"
        case apiConfigurationError = "API_CONFIGURATION_ERROR"
        case authorizerConfigurationError = "AUTHORIZER_CONFIGURATION_ERROR"
        case authorizerFailure = "AUTHORIZER_FAILURE"
        case badRequestBody = "BAD_REQUEST_BODY"
        case badRequestParameters = "BAD_REQUEST_PARAMETERS"
        case default4Xx = "DEFAULT_4XX"
        case default5Xx = "DEFAULT_5XX"
        case expiredToken = "EXPIRED_TOKEN"
        case integrationFailure = "INTEGRATION_FAILURE"
        case integrationTimeout = "INTEGRATION_TIMEOUT"
        case invalidApiKey = "INVALID_API_KEY"
        case invalidSignature = "INVALID_SIGNATURE"
        case missingAuthenticationToken = "MISSING_AUTHENTICATION_TOKEN"
        case quotaExceeded = "QUOTA_EXCEEDED"
        case requestTooLarge = "REQUEST_TOO_LARGE"
        case resourceNotFound = "RESOURCE_NOT_FOUND"
        case throttled = "THROTTLED"
        case unauthorized = "UNAUTHORIZED"
        case unsupportedMediaType = "UNSUPPORTED_MEDIA_TYPE"
        case wafFiltered = "WAF_FILTERED"
        public var description: String { return self.rawValue }
    }

    public enum IntegrationType: String, CustomStringConvertible, Codable, Sendable, CodingKeyRepresentable {
        case aws = "AWS"
        case awsProxy = "AWS_PROXY"
        case http = "HTTP"
        case httpProxy = "HTTP_PROXY"
        case mock = "MOCK"
        public var description: String { return self.rawValue }
    }

    public enum IpAddressType: String, CustomStringConvertible, Codable, Sendable, CodingKeyRepresentable {
        case dualstack = "dualstack"
        case ipv4 = "ipv4"
        public var description: String { return self.rawValue }
    }

    public enum LocationStatusType: String, CustomStringConvertible, Codable, Sendable, CodingKeyRepresentable {
        case documented = "DOCUMENTED"
        case undocumented = "UNDOCUMENTED"
        public var description: String { return self.rawValue }
    }

    public enum Op: String, CustomStringConvertible, Codable, Sendable, CodingKeyRepresentable {
        case add = "add"
        case copy = "copy"
        case move = "move"
        case remove = "remove"
        case replace = "replace"
        case test = "test"
        public var description: String { return self.rawValue }
    }

    public enum PutMode: String, CustomStringConvertible, Codable, Sendable, CodingKeyRepresentable {
        case merge = "merge"
        case overwrite = "overwrite"
        public var description: String { return self.rawValue }
    }

    public enum QuotaPeriodType: String, CustomStringConvertible, Codable, Sendable, CodingKeyRepresentable {
        case day = "DAY"
        case month = "MONTH"
        case week = "WEEK"
        public var description: String { return self.rawValue }
    }

    public enum ResourceOwner: String, CustomStringConvertible, Codable, Sendable, CodingKeyRepresentable {
        case _self = "SELF"
        case otherAccounts = "OTHER_ACCOUNTS"
        public var description: String { return self.rawValue }
    }

    public enum RoutingMode: String, CustomStringConvertible, Codable, Sendable, CodingKeyRepresentable {
        case basePathMappingOnly = "BASE_PATH_MAPPING_ONLY"
        case routingRuleOnly = "ROUTING_RULE_ONLY"
        case routingRuleThenBasePathMapping = "ROUTING_RULE_THEN_BASE_PATH_MAPPING"
        public var description: String { return self.rawValue }
    }

    public enum SecurityPolicy: String, CustomStringConvertible, Codable, Sendable, CodingKeyRepresentable {
        case tls10 = "TLS_1_0"
        case tls12 = "TLS_1_2"
        public var description: String { return self.rawValue }
    }

    public enum UnauthorizedCacheControlHeaderStrategy: String, CustomStringConvertible, Codable, Sendable, CodingKeyRepresentable {
        case failWith403 = "FAIL_WITH_403"
        case succeedWithResponseHeader = "SUCCEED_WITH_RESPONSE_HEADER"
        case succeedWithoutResponseHeader = "SUCCEED_WITHOUT_RESPONSE_HEADER"
        public var description: String { return self.rawValue }
    }

    public enum VpcLinkStatus: String, CustomStringConvertible, Codable, Sendable, CodingKeyRepresentable {
        case available = "AVAILABLE"
        case deleting = "DELETING"
        case failed = "FAILED"
        case pending = "PENDING"
        public var description: String { return self.rawValue }
    }

    // MARK: Shapes

    public struct AccessLogSettings: AWSDecodableShape {
        /// The Amazon Resource Name (ARN) of the CloudWatch Logs log group or Kinesis Data Firehose delivery stream to receive access logs. If you specify a Kinesis Data Firehose delivery stream, the stream name must begin with amazon-apigateway-.
        public let destinationArn: String?
        /// A single line format of the access logs of data, as specified by selected $context variables. The format must include at least $context.requestId.
        public let format: String?

        @inlinable
        public init(destinationArn: String? = nil, format: String? = nil) {
            self.destinationArn = destinationArn
            self.format = format
        }

        private enum CodingKeys: String, CodingKey {
            case destinationArn = "destinationArn"
            case format = "format"
        }
    }

    public struct Account: AWSDecodableShape {
        /// The version of the API keys used for the account.
        public let apiKeyVersion: String?
        /// The ARN of an Amazon CloudWatch role for the current Account.
        public let cloudwatchRoleArn: String?
        /// A list of features supported for the account. When usage plans are enabled, the features list will include an entry of "UsagePlans".
        public let features: [String]?
        /// Specifies the API request limits configured for the current Account.
        public let throttleSettings: ThrottleSettings?

        @inlinable
        public init(apiKeyVersion: String? = nil, cloudwatchRoleArn: String? = nil, features: [String]? = nil, throttleSettings: ThrottleSettings? = nil) {
            self.apiKeyVersion = apiKeyVersion
            self.cloudwatchRoleArn = cloudwatchRoleArn
            self.features = features
            self.throttleSettings = throttleSettings
        }

        private enum CodingKeys: String, CodingKey {
            case apiKeyVersion = "apiKeyVersion"
            case cloudwatchRoleArn = "cloudwatchRoleArn"
            case features = "features"
            case throttleSettings = "throttleSettings"
        }
    }

    public struct ApiKey: AWSDecodableShape {
        /// The timestamp when the API Key was created.
        public let createdDate: Date?
        /// An Amazon Web Services Marketplace customer identifier, when integrating with the Amazon Web Services SaaS Marketplace.
        public let customerId: String?
        /// The description of the API Key.
        public let description: String?
        /// Specifies whether the API Key can be used by callers.
        public let enabled: Bool?
        /// The identifier of the API Key.
        public let id: String?
        /// The timestamp when the API Key was last updated.
        public let lastUpdatedDate: Date?
        /// The name of the API Key.
        public let name: String?
        /// A list of Stage resources that are associated with the ApiKey resource.
        public let stageKeys: [String]?
        /// The collection of tags. Each tag element is associated with a given resource.
        public let tags: [String: String]?
        /// The value of the API Key.
        public let value: String?

        @inlinable
        public init(createdDate: Date? = nil, customerId: String? = nil, description: String? = nil, enabled: Bool? = nil, id: String? = nil, lastUpdatedDate: Date? = nil, name: String? = nil, stageKeys: [String]? = nil, tags: [String: String]? = nil, value: String? = nil) {
            self.createdDate = createdDate
            self.customerId = customerId
            self.description = description
            self.enabled = enabled
            self.id = id
            self.lastUpdatedDate = lastUpdatedDate
            self.name = name
            self.stageKeys = stageKeys
            self.tags = tags
            self.value = value
        }

        private enum CodingKeys: String, CodingKey {
            case createdDate = "createdDate"
            case customerId = "customerId"
            case description = "description"
            case enabled = "enabled"
            case id = "id"
            case lastUpdatedDate = "lastUpdatedDate"
            case name = "name"
            case stageKeys = "stageKeys"
            case tags = "tags"
            case value = "value"
        }
    }

    public struct ApiKeyIds: AWSDecodableShape {
        /// A list of all the ApiKey identifiers.
        public let ids: [String]?
        /// A list of warning messages.
        public let warnings: [String]?

        @inlinable
        public init(ids: [String]? = nil, warnings: [String]? = nil) {
            self.ids = ids
            self.warnings = warnings
        }

        private enum CodingKeys: String, CodingKey {
            case ids = "ids"
            case warnings = "warnings"
        }
    }

    public struct ApiKeys: AWSDecodableShape {
        /// The current page of elements from this collection.
        public let items: [ApiKey]?
        /// The current pagination position in the paged result set.
        public let position: String?
        /// A list of warning messages logged during the import of API keys when the failOnWarnings option is set to true.
        public let warnings: [String]?

        @inlinable
        public init(items: [ApiKey]? = nil, position: String? = nil, warnings: [String]? = nil) {
            self.items = items
            self.position = position
            self.warnings = warnings
        }

        private enum CodingKeys: String, CodingKey {
            case items = "item"
            case position = "position"
            case warnings = "warnings"
        }
    }

    public struct ApiStage: AWSEncodableShape & AWSDecodableShape {
        /// API Id of the associated API stage in a usage plan.
        public let apiId: String?
        /// API stage name of the associated API stage in a usage plan.
        public let stage: String?
        /// Map containing method level throttling information for API stage in a usage plan.
        public let throttle: [String: ThrottleSettings]?

        @inlinable
        public init(apiId: String? = nil, stage: String? = nil, throttle: [String: ThrottleSettings]? = nil) {
            self.apiId = apiId
            self.stage = stage
            self.throttle = throttle
        }

        private enum CodingKeys: String, CodingKey {
            case apiId = "apiId"
            case stage = "stage"
            case throttle = "throttle"
        }
    }

    public struct Authorizer: AWSDecodableShape {
        /// Specifies the required credentials as an IAM role for API Gateway to invoke the authorizer. To specify an IAM role for API Gateway to assume, use the role's Amazon Resource Name (ARN). To use resource-based permissions on the Lambda function, specify null.
        public let authorizerCredentials: String?
        /// The TTL in seconds of cached authorizer results. If it equals 0, authorization caching is disabled. If it is greater than 0, API Gateway will cache authorizer responses. If this field is not set, the default value is 300. The maximum value is 3600, or 1 hour.
        public let authorizerResultTtlInSeconds: Int?
        /// Specifies the authorizer's Uniform Resource Identifier (URI). For TOKEN or REQUEST authorizers, this must be a well-formed Lambda function URI, for example, arn:aws:apigateway:us-west-2:lambda:path/2015-03-31/functions/arn:aws:lambda:us-west-2:{account_id}:function:{lambda_function_name}/invocations. In general, the URI has this form  arn:aws:apigateway:{region}:lambda:path/{service_api}, where {region} is the same as the region hosting the Lambda function, path indicates that the remaining substring in the URI should be treated as the path to the resource, including the initial /. For Lambda functions, this is usually of the form /2015-03-31/functions/[FunctionARN]/invocations.
        public let authorizerUri: String?
        /// Optional customer-defined field, used in OpenAPI imports and exports without functional impact.
        public let authType: String?
        /// The identifier for the authorizer resource.
        public let id: String?
        /// The identity source for which authorization is requested. For a TOKEN or COGNITO_USER_POOLS authorizer, this is required and specifies the request header mapping expression for the custom header holding the authorization token submitted by the client. For example, if the token header name is Auth, the header mapping expression is method.request.header.Auth. For the REQUEST authorizer, this is required when authorization caching is enabled. The value is a comma-separated string of one or more mapping expressions of the specified request parameters. For example, if an Auth header, a Name query string parameter are defined as identity sources, this value is method.request.header.Auth, method.request.querystring.Name. These parameters will be used to derive the authorization caching key and to perform runtime validation of the REQUEST authorizer by verifying all of the identity-related request parameters are present, not null and non-empty. Only when this is true does the authorizer invoke the authorizer Lambda function, otherwise, it returns a 401 Unauthorized response without calling the Lambda function. The valid value is a string of comma-separated mapping expressions of the specified request parameters. When the authorization caching is not enabled, this property is optional.
        public let identitySource: String?
        /// A validation expression for the incoming identity token. For TOKEN authorizers, this value is a regular expression. For COGNITO_USER_POOLS authorizers, API Gateway will match the aud field of the incoming token from the client against the specified regular expression. It will invoke the authorizer's Lambda function when there is a match. Otherwise, it will return a 401 Unauthorized response without calling the Lambda function. The validation expression does not apply to the REQUEST authorizer.
        public let identityValidationExpression: String?
        /// The name of the authorizer.
        public let name: String?
        /// A list of the Amazon Cognito user pool ARNs for the COGNITO_USER_POOLS authorizer. Each element is of this format: arn:aws:cognito-idp:{region}:{account_id}:userpool/{user_pool_id}. For a TOKEN or REQUEST authorizer, this is not defined.
        public let providerARNs: [String]?
        /// The authorizer type. Valid values are TOKEN for a Lambda function using a single authorization token submitted in a custom header, REQUEST for a Lambda function using incoming request parameters, and COGNITO_USER_POOLS for using an Amazon Cognito user pool.
        public let type: AuthorizerType?

        @inlinable
        public init(authorizerCredentials: String? = nil, authorizerResultTtlInSeconds: Int? = nil, authorizerUri: String? = nil, authType: String? = nil, id: String? = nil, identitySource: String? = nil, identityValidationExpression: String? = nil, name: String? = nil, providerARNs: [String]? = nil, type: AuthorizerType? = nil) {
            self.authorizerCredentials = authorizerCredentials
            self.authorizerResultTtlInSeconds = authorizerResultTtlInSeconds
            self.authorizerUri = authorizerUri
            self.authType = authType
            self.id = id
            self.identitySource = identitySource
            self.identityValidationExpression = identityValidationExpression
            self.name = name
            self.providerARNs = providerARNs
            self.type = type
        }

        private enum CodingKeys: String, CodingKey {
            case authorizerCredentials = "authorizerCredentials"
            case authorizerResultTtlInSeconds = "authorizerResultTtlInSeconds"
            case authorizerUri = "authorizerUri"
            case authType = "authType"
            case id = "id"
            case identitySource = "identitySource"
            case identityValidationExpression = "identityValidationExpression"
            case name = "name"
            case providerARNs = "providerARNs"
            case type = "type"
        }
    }

    public struct Authorizers: AWSDecodableShape {
        /// The current page of elements from this collection.
        public let items: [Authorizer]?
        /// The current pagination position in the paged result set.
        public let position: String?

        @inlinable
        public init(items: [Authorizer]? = nil, position: String? = nil) {
            self.items = items
            self.position = position
        }

        private enum CodingKeys: String, CodingKey {
            case items = "item"
            case position = "position"
        }
    }

    public struct BasePathMapping: AWSDecodableShape {
        /// The base path name that callers of the API must provide as part of the URL after the domain name.
        public let basePath: String?
        /// The string identifier of the associated RestApi.
        public let restApiId: String?
        /// The name of the associated stage.
        public let stage: String?

        @inlinable
        public init(basePath: String? = nil, restApiId: String? = nil, stage: String? = nil) {
            self.basePath = basePath
            self.restApiId = restApiId
            self.stage = stage
        }

        private enum CodingKeys: String, CodingKey {
            case basePath = "basePath"
            case restApiId = "restApiId"
            case stage = "stage"
        }
    }

    public struct BasePathMappings: AWSDecodableShape {
        /// The current page of elements from this collection.
        public let items: [BasePathMapping]?
        /// The current pagination position in the paged result set.
        public let position: String?

        @inlinable
        public init(items: [BasePathMapping]? = nil, position: String? = nil) {
            self.items = items
            self.position = position
        }

        private enum CodingKeys: String, CodingKey {
            case items = "item"
            case position = "position"
        }
    }

    public struct CanarySettings: AWSEncodableShape & AWSDecodableShape {
        /// The ID of the canary deployment.
        public let deploymentId: String?
        /// The percent (0-100) of traffic diverted to a canary deployment.
        public let percentTraffic: Double?
        /// Stage variables overridden for a canary release deployment, including new stage variables introduced in the canary. These stage variables are represented as a string-to-string map between stage variable names and their values.
        public let stageVariableOverrides: [String: String]?
        /// A Boolean flag to indicate whether the canary deployment uses the stage cache or not.
        public let useStageCache: Bool?

        @inlinable
        public init(deploymentId: String? = nil, percentTraffic: Double? = nil, stageVariableOverrides: [String: String]? = nil, useStageCache: Bool? = nil) {
            self.deploymentId = deploymentId
            self.percentTraffic = percentTraffic
            self.stageVariableOverrides = stageVariableOverrides
            self.useStageCache = useStageCache
        }

        private enum CodingKeys: String, CodingKey {
            case deploymentId = "deploymentId"
            case percentTraffic = "percentTraffic"
            case stageVariableOverrides = "stageVariableOverrides"
            case useStageCache = "useStageCache"
        }
    }

    public struct ClientCertificate: AWSDecodableShape {
        /// The identifier of the client certificate.
        public let clientCertificateId: String?
        /// The timestamp when the client certificate was created.
        public let createdDate: Date?
        /// The description of the client certificate.
        public let description: String?
        /// The timestamp when the client certificate will expire.
        public let expirationDate: Date?
        /// The PEM-encoded public key of the client certificate, which can be used to configure certificate authentication in the integration endpoint .
        public let pemEncodedCertificate: String?
        /// The collection of tags. Each tag element is associated with a given resource.
        public let tags: [String: String]?

        @inlinable
        public init(clientCertificateId: String? = nil, createdDate: Date? = nil, description: String? = nil, expirationDate: Date? = nil, pemEncodedCertificate: String? = nil, tags: [String: String]? = nil) {
            self.clientCertificateId = clientCertificateId
            self.createdDate = createdDate
            self.description = description
            self.expirationDate = expirationDate
            self.pemEncodedCertificate = pemEncodedCertificate
            self.tags = tags
        }

        private enum CodingKeys: String, CodingKey {
            case clientCertificateId = "clientCertificateId"
            case createdDate = "createdDate"
            case description = "description"
            case expirationDate = "expirationDate"
            case pemEncodedCertificate = "pemEncodedCertificate"
            case tags = "tags"
        }
    }

    public struct ClientCertificates: AWSDecodableShape {
        /// The current page of elements from this collection.
        public let items: [ClientCertificate]?
        /// The current pagination position in the paged result set.
        public let position: String?

        @inlinable
        public init(items: [ClientCertificate]? = nil, position: String? = nil) {
            self.items = items
            self.position = position
        }

        private enum CodingKeys: String, CodingKey {
            case items = "item"
            case position = "position"
        }
    }

    public struct CreateApiKeyRequest: AWSEncodableShape {
        /// An Amazon Web Services Marketplace customer identifier, when integrating with the Amazon Web Services SaaS Marketplace.
        public let customerId: String?
        /// The description of the ApiKey.
        public let description: String?
        /// Specifies whether the ApiKey can be used by callers.
        public let enabled: Bool?
        /// Specifies whether (true) or not (false) the key identifier is distinct from the created API key value. This parameter is deprecated and should not be used.
        public let generateDistinctId: Bool?
        /// The name of the ApiKey.
        public let name: String?
        /// DEPRECATED FOR USAGE PLANS - Specifies stages associated with the API key.
        public let stageKeys: [StageKey]?
        /// The key-value map of strings. The valid character set is [a-zA-Z+-=._:/]. The tag key can be up to 128 characters and must not start with aws:. The tag value can be up to 256 characters.
        public let tags: [String: String]?
        /// Specifies a value of the API key.
        public let value: String?

        @inlinable
        public init(customerId: String? = nil, description: String? = nil, enabled: Bool? = nil, generateDistinctId: Bool? = nil, name: String? = nil, stageKeys: [StageKey]? = nil, tags: [String: String]? = nil, value: String? = nil) {
            self.customerId = customerId
            self.description = description
            self.enabled = enabled
            self.generateDistinctId = generateDistinctId
            self.name = name
            self.stageKeys = stageKeys
            self.tags = tags
            self.value = value
        }

        private enum CodingKeys: String, CodingKey {
            case customerId = "customerId"
            case description = "description"
            case enabled = "enabled"
            case generateDistinctId = "generateDistinctId"
            case name = "name"
            case stageKeys = "stageKeys"
            case tags = "tags"
            case value = "value"
        }
    }

    public struct CreateAuthorizerRequest: AWSEncodableShape {
        /// Specifies the required credentials as an IAM role for API Gateway to invoke the authorizer. To specify an IAM role for API Gateway to assume, use the role's Amazon Resource Name (ARN). To use resource-based permissions on the Lambda function, specify null.
        public let authorizerCredentials: String?
        /// The TTL in seconds of cached authorizer results. If it equals 0, authorization caching is disabled. If it is greater than 0, API Gateway will cache authorizer responses. If this field is not set, the default value is 300. The maximum value is 3600, or 1 hour.
        public let authorizerResultTtlInSeconds: Int?
        /// Specifies the authorizer's Uniform Resource Identifier (URI). For TOKEN or REQUEST authorizers, this must be a well-formed Lambda function URI, for example, arn:aws:apigateway:us-west-2:lambda:path/2015-03-31/functions/arn:aws:lambda:us-west-2:{account_id}:function:{lambda_function_name}/invocations. In general, the URI has this form  arn:aws:apigateway:{region}:lambda:path/{service_api}, where {region} is the same as the region hosting the Lambda function, path indicates that the remaining substring in the URI should be treated as the path to the resource, including the initial /. For Lambda functions, this is usually of the form /2015-03-31/functions/[FunctionARN]/invocations.
        public let authorizerUri: String?
        /// Optional customer-defined field, used in OpenAPI imports and exports without functional impact.
        public let authType: String?
        /// The identity source for which authorization is requested. For a TOKEN or COGNITO_USER_POOLS authorizer, this is required and specifies the request header mapping expression for the custom header holding the authorization token submitted by the client. For example, if the token header name is Auth, the header mapping expression is method.request.header.Auth. For the REQUEST authorizer, this is required when authorization caching is enabled. The value is a comma-separated string of one or more mapping expressions of the specified request parameters. For example, if an Auth header, a Name query string parameter are defined as identity sources, this value is method.request.header.Auth, method.request.querystring.Name. These parameters will be used to derive the authorization caching key and to perform runtime validation of the REQUEST authorizer by verifying all of the identity-related request parameters are present, not null and non-empty. Only when this is true does the authorizer invoke the authorizer Lambda function, otherwise, it returns a 401 Unauthorized response without calling the Lambda function. The valid value is a string of comma-separated mapping expressions of the specified request parameters. When the authorization caching is not enabled, this property is optional.
        public let identitySource: String?
        /// A validation expression for the incoming identity token. For TOKEN authorizers, this value is a regular expression. For COGNITO_USER_POOLS authorizers, API Gateway will match the aud field of the incoming token from the client against the specified regular expression. It will invoke the authorizer's Lambda function when there is a match. Otherwise, it will return a 401 Unauthorized response without calling the Lambda function. The validation expression does not apply to the REQUEST authorizer.
        public let identityValidationExpression: String?
        /// The name of the authorizer.
        public let name: String
        /// A list of the Amazon Cognito user pool ARNs for the COGNITO_USER_POOLS authorizer. Each element is of this format: arn:aws:cognito-idp:{region}:{account_id}:userpool/{user_pool_id}. For a TOKEN or REQUEST authorizer, this is not defined.
        public let providerARNs: [String]?
        /// The string identifier of the associated RestApi.
        public let restApiId: String
        /// The authorizer type. Valid values are TOKEN for a Lambda function using a single authorization token submitted in a custom header, REQUEST for a Lambda function using incoming request parameters, and COGNITO_USER_POOLS for using an Amazon Cognito user pool.
        public let type: AuthorizerType

        @inlinable
        public init(authorizerCredentials: String? = nil, authorizerResultTtlInSeconds: Int? = nil, authorizerUri: String? = nil, authType: String? = nil, identitySource: String? = nil, identityValidationExpression: String? = nil, name: String, providerARNs: [String]? = nil, restApiId: String, type: AuthorizerType) {
            self.authorizerCredentials = authorizerCredentials
            self.authorizerResultTtlInSeconds = authorizerResultTtlInSeconds
            self.authorizerUri = authorizerUri
            self.authType = authType
            self.identitySource = identitySource
            self.identityValidationExpression = identityValidationExpression
            self.name = name
            self.providerARNs = providerARNs
            self.restApiId = restApiId
            self.type = type
        }

        public func encode(to encoder: Encoder) throws {
            let request = encoder.userInfo[.awsRequest]! as! RequestEncodingContainer
            var container = encoder.container(keyedBy: CodingKeys.self)
            try container.encodeIfPresent(self.authorizerCredentials, forKey: .authorizerCredentials)
            try container.encodeIfPresent(self.authorizerResultTtlInSeconds, forKey: .authorizerResultTtlInSeconds)
            try container.encodeIfPresent(self.authorizerUri, forKey: .authorizerUri)
            try container.encodeIfPresent(self.authType, forKey: .authType)
            try container.encodeIfPresent(self.identitySource, forKey: .identitySource)
            try container.encodeIfPresent(self.identityValidationExpression, forKey: .identityValidationExpression)
            try container.encode(self.name, forKey: .name)
            try container.encodeIfPresent(self.providerARNs, forKey: .providerARNs)
            request.encodePath(self.restApiId, key: "restApiId")
            try container.encode(self.type, forKey: .type)
        }

        private enum CodingKeys: String, CodingKey {
            case authorizerCredentials = "authorizerCredentials"
            case authorizerResultTtlInSeconds = "authorizerResultTtlInSeconds"
            case authorizerUri = "authorizerUri"
            case authType = "authType"
            case identitySource = "identitySource"
            case identityValidationExpression = "identityValidationExpression"
            case name = "name"
            case providerARNs = "providerARNs"
            case type = "type"
        }
    }

    public struct CreateBasePathMappingRequest: AWSEncodableShape {
        /// The base path name that callers of the API must provide as part of the URL after the domain name. This value must be unique for all of the mappings across a single API. Specify '(none)' if you do not want callers to specify a base path name after the domain name.
        public let basePath: String?
        /// The domain name of the BasePathMapping resource to create.
        public let domainName: String
        /// The identifier for the domain name resource. Required for private custom domain names.
        public let domainNameId: String?
        /// The string identifier of the associated RestApi.
        public let restApiId: String
        /// The name of the API's stage that you want to use for this mapping. Specify '(none)' if you want callers to explicitly specify the stage name after any base path name.
        public let stage: String?

        @inlinable
        public init(basePath: String? = nil, domainName: String, domainNameId: String? = nil, restApiId: String, stage: String? = nil) {
            self.basePath = basePath
            self.domainName = domainName
            self.domainNameId = domainNameId
            self.restApiId = restApiId
            self.stage = stage
        }

        public func encode(to encoder: Encoder) throws {
            let request = encoder.userInfo[.awsRequest]! as! RequestEncodingContainer
            var container = encoder.container(keyedBy: CodingKeys.self)
            try container.encodeIfPresent(self.basePath, forKey: .basePath)
            request.encodePath(self.domainName, key: "domainName")
            request.encodeQuery(self.domainNameId, key: "domainNameId")
            try container.encode(self.restApiId, forKey: .restApiId)
            try container.encodeIfPresent(self.stage, forKey: .stage)
        }

        private enum CodingKeys: String, CodingKey {
            case basePath = "basePath"
            case restApiId = "restApiId"
            case stage = "stage"
        }
    }

    public struct CreateDeploymentRequest: AWSEncodableShape {
        /// Enables a cache cluster for the Stage resource specified in the input.
        public let cacheClusterEnabled: Bool?
        /// The stage's cache capacity in GB. For more information about choosing a cache size, see Enabling API caching to enhance responsiveness.
        public let cacheClusterSize: CacheClusterSize?
        /// The input configuration for the canary deployment when the deployment is a canary release deployment.
        public let canarySettings: DeploymentCanarySettings?
        /// The description for the Deployment resource to create.
        public let description: String?
        /// The string identifier of the associated RestApi.
        public let restApiId: String
        /// The description of the Stage resource for the Deployment resource to create.
        public let stageDescription: String?
        /// The name of the Stage resource for the Deployment resource to create.
        public let stageName: String?
        /// Specifies whether active tracing with X-ray is enabled for the Stage.
        public let tracingEnabled: Bool?
        /// A map that defines the stage variables for the Stage resource that is associated with the new deployment. Variable names can have alphanumeric and underscore characters, and the values must match [A-Za-z0-9-._~:/?#&=,]+.
        public let variables: [String: String]?

        @inlinable
        public init(cacheClusterEnabled: Bool? = nil, cacheClusterSize: CacheClusterSize? = nil, canarySettings: DeploymentCanarySettings? = nil, description: String? = nil, restApiId: String, stageDescription: String? = nil, stageName: String? = nil, tracingEnabled: Bool? = nil, variables: [String: String]? = nil) {
            self.cacheClusterEnabled = cacheClusterEnabled
            self.cacheClusterSize = cacheClusterSize
            self.canarySettings = canarySettings
            self.description = description
            self.restApiId = restApiId
            self.stageDescription = stageDescription
            self.stageName = stageName
            self.tracingEnabled = tracingEnabled
            self.variables = variables
        }

        public func encode(to encoder: Encoder) throws {
            let request = encoder.userInfo[.awsRequest]! as! RequestEncodingContainer
            var container = encoder.container(keyedBy: CodingKeys.self)
            try container.encodeIfPresent(self.cacheClusterEnabled, forKey: .cacheClusterEnabled)
            try container.encodeIfPresent(self.cacheClusterSize, forKey: .cacheClusterSize)
            try container.encodeIfPresent(self.canarySettings, forKey: .canarySettings)
            try container.encodeIfPresent(self.description, forKey: .description)
            request.encodePath(self.restApiId, key: "restApiId")
            try container.encodeIfPresent(self.stageDescription, forKey: .stageDescription)
            try container.encodeIfPresent(self.stageName, forKey: .stageName)
            try container.encodeIfPresent(self.tracingEnabled, forKey: .tracingEnabled)
            try container.encodeIfPresent(self.variables, forKey: .variables)
        }

        private enum CodingKeys: String, CodingKey {
            case cacheClusterEnabled = "cacheClusterEnabled"
            case cacheClusterSize = "cacheClusterSize"
            case canarySettings = "canarySettings"
            case description = "description"
            case stageDescription = "stageDescription"
            case stageName = "stageName"
            case tracingEnabled = "tracingEnabled"
            case variables = "variables"
        }
    }

    public struct CreateDocumentationPartRequest: AWSEncodableShape {
        /// The location of the targeted API entity of the to-be-created documentation part.
        public let location: DocumentationPartLocation
        /// The new documentation content map of the targeted API entity. Enclosed key-value pairs are API-specific, but only OpenAPI-compliant key-value pairs can be exported and, hence, published.
        public let properties: String
        /// The string identifier of the associated RestApi.
        public let restApiId: String

        @inlinable
        public init(location: DocumentationPartLocation, properties: String, restApiId: String) {
            self.location = location
            self.properties = properties
            self.restApiId = restApiId
        }

        public func encode(to encoder: Encoder) throws {
            let request = encoder.userInfo[.awsRequest]! as! RequestEncodingContainer
            var container = encoder.container(keyedBy: CodingKeys.self)
            try container.encode(self.location, forKey: .location)
            try container.encode(self.properties, forKey: .properties)
            request.encodePath(self.restApiId, key: "restApiId")
        }

        public func validate(name: String) throws {
            try self.location.validate(name: "\(name).location")
        }

        private enum CodingKeys: String, CodingKey {
            case location = "location"
            case properties = "properties"
        }
    }

    public struct CreateDocumentationVersionRequest: AWSEncodableShape {
        /// A description about the new documentation snapshot.
        public let description: String?
        /// The version identifier of the new snapshot.
        public let documentationVersion: String
        /// The string identifier of the associated RestApi.
        public let restApiId: String
        /// The stage name to be associated with the new documentation snapshot.
        public let stageName: String?

        @inlinable
        public init(description: String? = nil, documentationVersion: String, restApiId: String, stageName: String? = nil) {
            self.description = description
            self.documentationVersion = documentationVersion
            self.restApiId = restApiId
            self.stageName = stageName
        }

        public func encode(to encoder: Encoder) throws {
            let request = encoder.userInfo[.awsRequest]! as! RequestEncodingContainer
            var container = encoder.container(keyedBy: CodingKeys.self)
            try container.encodeIfPresent(self.description, forKey: .description)
            try container.encode(self.documentationVersion, forKey: .documentationVersion)
            request.encodePath(self.restApiId, key: "restApiId")
            try container.encodeIfPresent(self.stageName, forKey: .stageName)
        }

        private enum CodingKeys: String, CodingKey {
            case description = "description"
            case documentationVersion = "documentationVersion"
            case stageName = "stageName"
        }
    }

    public struct CreateDomainNameAccessAssociationRequest: AWSEncodableShape {
        /// The identifier of the domain name access association source. For a VPCE, the value is the VPC endpoint ID.
        public let accessAssociationSource: String
        /// The type of the domain name access association source.
        public let accessAssociationSourceType: AccessAssociationSourceType
        ///  The ARN of the domain name.
        public let domainNameArn: String
        /// The key-value map of strings. The valid character set is [a-zA-Z+-=._:/]. The tag key can be up to 128 characters and must not start with aws:. The tag value can be up to 256 characters.
        public let tags: [String: String]?

        @inlinable
        public init(accessAssociationSource: String, accessAssociationSourceType: AccessAssociationSourceType, domainNameArn: String, tags: [String: String]? = nil) {
            self.accessAssociationSource = accessAssociationSource
            self.accessAssociationSourceType = accessAssociationSourceType
            self.domainNameArn = domainNameArn
            self.tags = tags
        }

        private enum CodingKeys: String, CodingKey {
            case accessAssociationSource = "accessAssociationSource"
            case accessAssociationSourceType = "accessAssociationSourceType"
            case domainNameArn = "domainNameArn"
            case tags = "tags"
        }
    }

    public struct CreateDomainNameRequest: AWSEncodableShape {
        /// The reference to an Amazon Web Services-managed certificate that will be used by edge-optimized endpoint or private endpoint for this domain name. Certificate Manager is the only supported source.
        public let certificateArn: String?
        /// [Deprecated] The body of the server certificate that will be used by edge-optimized endpoint or private endpoint for this domain name provided by your certificate authority.
        public let certificateBody: String?
        /// [Deprecated] The intermediate certificates and optionally the root certificate, one after the other without any blank lines, used by an edge-optimized endpoint for this domain name. If you include the root certificate, your certificate chain must start with intermediate certificates and end with the root certificate. Use the intermediate certificates that were provided by your certificate authority. Do not include any intermediaries that are not in the chain of trust path.
        public let certificateChain: String?
        /// The user-friendly name of the certificate that will be used by edge-optimized endpoint or private endpoint for this domain name.
        public let certificateName: String?
        /// [Deprecated] Your edge-optimized endpoint's domain name certificate's private key.
        public let certificatePrivateKey: String?
        /// The name of the DomainName resource.
        public let domainName: String
        /// The endpoint configuration of this DomainName showing the endpoint types and IP address types of the domain name.
        public let endpointConfiguration: EndpointConfiguration?
        public let mutualTlsAuthentication: MutualTlsAuthenticationInput?
        /// The ARN of the public certificate issued by ACM to validate ownership of your custom domain. Only required when configuring mutual TLS and using an ACM imported or private CA certificate ARN as the regionalCertificateArn.
        public let ownershipVerificationCertificateArn: String?
        /// A stringified JSON policy document that applies to the execute-api service for this DomainName regardless of the caller and Method configuration. Supported only for private custom domain names.
        public let policy: String?
        /// The reference to an Amazon Web Services-managed certificate that will be used by regional endpoint for this domain name. Certificate Manager is the only supported source.
        public let regionalCertificateArn: String?
        /// The user-friendly name of the certificate that will be used by regional endpoint for this domain name.
        public let regionalCertificateName: String?
        /// The routing mode for this domain name. The routing mode determines how API Gateway sends traffic from your custom domain name to your private APIs.
        public let routingMode: RoutingMode?
        /// The Transport Layer Security (TLS) version + cipher suite for this DomainName. The valid values are TLS_1_0 and TLS_1_2.
        public let securityPolicy: SecurityPolicy?
        /// The key-value map of strings. The valid character set is [a-zA-Z+-=._:/]. The tag key can be up to 128 characters and must not start with aws:. The tag value can be up to 256 characters.
        public let tags: [String: String]?

        @inlinable
        public init(certificateArn: String? = nil, certificateBody: String? = nil, certificateChain: String? = nil, certificateName: String? = nil, certificatePrivateKey: String? = nil, domainName: String, endpointConfiguration: EndpointConfiguration? = nil, mutualTlsAuthentication: MutualTlsAuthenticationInput? = nil, ownershipVerificationCertificateArn: String? = nil, policy: String? = nil, regionalCertificateArn: String? = nil, regionalCertificateName: String? = nil, routingMode: RoutingMode? = nil, securityPolicy: SecurityPolicy? = nil, tags: [String: String]? = nil) {
            self.certificateArn = certificateArn
            self.certificateBody = certificateBody
            self.certificateChain = certificateChain
            self.certificateName = certificateName
            self.certificatePrivateKey = certificatePrivateKey
            self.domainName = domainName
            self.endpointConfiguration = endpointConfiguration
            self.mutualTlsAuthentication = mutualTlsAuthentication
            self.ownershipVerificationCertificateArn = ownershipVerificationCertificateArn
            self.policy = policy
            self.regionalCertificateArn = regionalCertificateArn
            self.regionalCertificateName = regionalCertificateName
            self.routingMode = routingMode
            self.securityPolicy = securityPolicy
            self.tags = tags
        }

        private enum CodingKeys: String, CodingKey {
            case certificateArn = "certificateArn"
            case certificateBody = "certificateBody"
            case certificateChain = "certificateChain"
            case certificateName = "certificateName"
            case certificatePrivateKey = "certificatePrivateKey"
            case domainName = "domainName"
            case endpointConfiguration = "endpointConfiguration"
            case mutualTlsAuthentication = "mutualTlsAuthentication"
            case ownershipVerificationCertificateArn = "ownershipVerificationCertificateArn"
            case policy = "policy"
            case regionalCertificateArn = "regionalCertificateArn"
            case regionalCertificateName = "regionalCertificateName"
            case routingMode = "routingMode"
            case securityPolicy = "securityPolicy"
            case tags = "tags"
        }
    }

    public struct CreateModelRequest: AWSEncodableShape {
        /// The content-type for the model.
        public let contentType: String
        /// The description of the model.
        public let description: String?
        /// The name of the model. Must be alphanumeric.
        public let name: String
        /// The RestApi identifier under which the Model will be created.
        public let restApiId: String
        /// The schema for the model. For application/json models, this should be JSON schema draft 4 model. The maximum size of the model is 400 KB.
        public let schema: String?

        @inlinable
        public init(contentType: String, description: String? = nil, name: String, restApiId: String, schema: String? = nil) {
            self.contentType = contentType
            self.description = description
            self.name = name
            self.restApiId = restApiId
            self.schema = schema
        }

        public func encode(to encoder: Encoder) throws {
            let request = encoder.userInfo[.awsRequest]! as! RequestEncodingContainer
            var container = encoder.container(keyedBy: CodingKeys.self)
            try container.encode(self.contentType, forKey: .contentType)
            try container.encodeIfPresent(self.description, forKey: .description)
            try container.encode(self.name, forKey: .name)
            request.encodePath(self.restApiId, key: "restApiId")
            try container.encodeIfPresent(self.schema, forKey: .schema)
        }

        private enum CodingKeys: String, CodingKey {
            case contentType = "contentType"
            case description = "description"
            case name = "name"
            case schema = "schema"
        }
    }

    public struct CreateRequestValidatorRequest: AWSEncodableShape {
        /// The name of the to-be-created RequestValidator.
        public let name: String?
        /// The string identifier of the associated RestApi.
        public let restApiId: String
        /// A Boolean flag to indicate whether to validate request body according to the configured model schema for the method (true) or not (false).
        public let validateRequestBody: Bool?
        /// A Boolean flag to indicate whether to validate request parameters, true, or not false.
        public let validateRequestParameters: Bool?

        @inlinable
        public init(name: String? = nil, restApiId: String, validateRequestBody: Bool? = nil, validateRequestParameters: Bool? = nil) {
            self.name = name
            self.restApiId = restApiId
            self.validateRequestBody = validateRequestBody
            self.validateRequestParameters = validateRequestParameters
        }

        public func encode(to encoder: Encoder) throws {
            let request = encoder.userInfo[.awsRequest]! as! RequestEncodingContainer
            var container = encoder.container(keyedBy: CodingKeys.self)
            try container.encodeIfPresent(self.name, forKey: .name)
            request.encodePath(self.restApiId, key: "restApiId")
            try container.encodeIfPresent(self.validateRequestBody, forKey: .validateRequestBody)
            try container.encodeIfPresent(self.validateRequestParameters, forKey: .validateRequestParameters)
        }

        private enum CodingKeys: String, CodingKey {
            case name = "name"
            case validateRequestBody = "validateRequestBody"
            case validateRequestParameters = "validateRequestParameters"
        }
    }

    public struct CreateResourceRequest: AWSEncodableShape {
        /// The parent resource's identifier.
        public let parentId: String
        /// The last path segment for this resource.
        public let pathPart: String
        /// The string identifier of the associated RestApi.
        public let restApiId: String

        @inlinable
        public init(parentId: String, pathPart: String, restApiId: String) {
            self.parentId = parentId
            self.pathPart = pathPart
            self.restApiId = restApiId
        }

        public func encode(to encoder: Encoder) throws {
            let request = encoder.userInfo[.awsRequest]! as! RequestEncodingContainer
            var container = encoder.container(keyedBy: CodingKeys.self)
            request.encodePath(self.parentId, key: "parentId")
            try container.encode(self.pathPart, forKey: .pathPart)
            request.encodePath(self.restApiId, key: "restApiId")
        }

        private enum CodingKeys: String, CodingKey {
            case pathPart = "pathPart"
        }
    }

    public struct CreateRestApiRequest: AWSEncodableShape {
        /// The source of the API key for metering requests according to a usage plan. Valid values are: HEADER to read the API key from the X-API-Key header of a request. AUTHORIZER to read the API key from the UsageIdentifierKey from a custom authorizer.
        public let apiKeySource: ApiKeySourceType?
        /// The list of binary media types supported by the RestApi. By default, the RestApi supports only UTF-8-encoded text payloads.
        public let binaryMediaTypes: [String]?
        /// The ID of the RestApi that you want to clone from.
        public let cloneFrom: String?
        /// The description of the RestApi.
        public let description: String?
        /// Specifies whether clients can invoke your API by using the default execute-api endpoint. By default, clients can invoke your API with the default https://{api_id}.execute-api.{region}.amazonaws.com endpoint. To require that clients use a custom domain name to invoke your API, disable the default endpoint
        public let disableExecuteApiEndpoint: Bool?
        /// The endpoint configuration of this RestApi showing the endpoint types and IP address types of the API.
        public let endpointConfiguration: EndpointConfiguration?
        /// A nullable integer that is used to enable compression (with non-negative between 0 and 10485760 (10M) bytes, inclusive) or disable compression (with a null value) on an API. When compression is enabled, compression or decompression is not applied on the payload if the payload size is smaller than this value. Setting it to zero allows compression for any payload size.
        public let minimumCompressionSize: Int?
        /// The name of the RestApi.
        public let name: String
        /// A stringified JSON policy document that applies to this RestApi regardless of the caller and Method configuration.
        public let policy: String?
        /// The key-value map of strings. The valid character set is [a-zA-Z+-=._:/]. The tag key can be up to 128 characters and must not start with aws:. The tag value can be up to 256 characters.
        public let tags: [String: String]?
        /// A version identifier for the API.
        public let version: String?

        @inlinable
        public init(apiKeySource: ApiKeySourceType? = nil, binaryMediaTypes: [String]? = nil, cloneFrom: String? = nil, description: String? = nil, disableExecuteApiEndpoint: Bool? = nil, endpointConfiguration: EndpointConfiguration? = nil, minimumCompressionSize: Int? = nil, name: String, policy: String? = nil, tags: [String: String]? = nil, version: String? = nil) {
            self.apiKeySource = apiKeySource
            self.binaryMediaTypes = binaryMediaTypes
            self.cloneFrom = cloneFrom
            self.description = description
            self.disableExecuteApiEndpoint = disableExecuteApiEndpoint
            self.endpointConfiguration = endpointConfiguration
            self.minimumCompressionSize = minimumCompressionSize
            self.name = name
            self.policy = policy
            self.tags = tags
            self.version = version
        }

        private enum CodingKeys: String, CodingKey {
            case apiKeySource = "apiKeySource"
            case binaryMediaTypes = "binaryMediaTypes"
            case cloneFrom = "cloneFrom"
            case description = "description"
            case disableExecuteApiEndpoint = "disableExecuteApiEndpoint"
            case endpointConfiguration = "endpointConfiguration"
            case minimumCompressionSize = "minimumCompressionSize"
            case name = "name"
            case policy = "policy"
            case tags = "tags"
            case version = "version"
        }
    }

    public struct CreateStageRequest: AWSEncodableShape {
        /// Whether cache clustering is enabled for the stage.
        public let cacheClusterEnabled: Bool?
        /// The stage's cache capacity in GB. For more information about choosing a cache size, see Enabling API caching to enhance responsiveness.
        public let cacheClusterSize: CacheClusterSize?
        /// The canary deployment settings of this stage.
        public let canarySettings: CanarySettings?
        /// The identifier of the Deployment resource for the Stage resource.
        public let deploymentId: String
        /// The description of the Stage resource.
        public let description: String?
        /// The version of the associated API documentation.
        public let documentationVersion: String?
        /// The string identifier of the associated RestApi.
        public let restApiId: String
        /// The name for the Stage resource. Stage names can only contain alphanumeric characters, hyphens, and underscores. Maximum length is 128 characters.
        public let stageName: String
        /// The key-value map of strings. The valid character set is [a-zA-Z+-=._:/]. The tag key can be up to 128 characters and must not start with aws:. The tag value can be up to 256 characters.
        public let tags: [String: String]?
        /// Specifies whether active tracing with X-ray is enabled for the Stage.
        public let tracingEnabled: Bool?
        /// A map that defines the stage variables for the new Stage resource. Variable names can have alphanumeric and underscore characters, and the values must match [A-Za-z0-9-._~:/?#&=,]+.
        public let variables: [String: String]?

        @inlinable
        public init(cacheClusterEnabled: Bool? = nil, cacheClusterSize: CacheClusterSize? = nil, canarySettings: CanarySettings? = nil, deploymentId: String, description: String? = nil, documentationVersion: String? = nil, restApiId: String, stageName: String, tags: [String: String]? = nil, tracingEnabled: Bool? = nil, variables: [String: String]? = nil) {
            self.cacheClusterEnabled = cacheClusterEnabled
            self.cacheClusterSize = cacheClusterSize
            self.canarySettings = canarySettings
            self.deploymentId = deploymentId
            self.description = description
            self.documentationVersion = documentationVersion
            self.restApiId = restApiId
            self.stageName = stageName
            self.tags = tags
            self.tracingEnabled = tracingEnabled
            self.variables = variables
        }

        public func encode(to encoder: Encoder) throws {
            let request = encoder.userInfo[.awsRequest]! as! RequestEncodingContainer
            var container = encoder.container(keyedBy: CodingKeys.self)
            try container.encodeIfPresent(self.cacheClusterEnabled, forKey: .cacheClusterEnabled)
            try container.encodeIfPresent(self.cacheClusterSize, forKey: .cacheClusterSize)
            try container.encodeIfPresent(self.canarySettings, forKey: .canarySettings)
            try container.encode(self.deploymentId, forKey: .deploymentId)
            try container.encodeIfPresent(self.description, forKey: .description)
            try container.encodeIfPresent(self.documentationVersion, forKey: .documentationVersion)
            request.encodePath(self.restApiId, key: "restApiId")
            try container.encode(self.stageName, forKey: .stageName)
            try container.encodeIfPresent(self.tags, forKey: .tags)
            try container.encodeIfPresent(self.tracingEnabled, forKey: .tracingEnabled)
            try container.encodeIfPresent(self.variables, forKey: .variables)
        }

        private enum CodingKeys: String, CodingKey {
            case cacheClusterEnabled = "cacheClusterEnabled"
            case cacheClusterSize = "cacheClusterSize"
            case canarySettings = "canarySettings"
            case deploymentId = "deploymentId"
            case description = "description"
            case documentationVersion = "documentationVersion"
            case stageName = "stageName"
            case tags = "tags"
            case tracingEnabled = "tracingEnabled"
            case variables = "variables"
        }
    }

    public struct CreateUsagePlanKeyRequest: AWSEncodableShape {
        /// The identifier of a UsagePlanKey resource for a plan customer.
        public let keyId: String
        /// The type of a UsagePlanKey resource for a plan customer.
        public let keyType: String
        /// The Id of the UsagePlan resource representing the usage plan containing the to-be-created UsagePlanKey resource representing a plan customer.
        public let usagePlanId: String

        @inlinable
        public init(keyId: String, keyType: String, usagePlanId: String) {
            self.keyId = keyId
            self.keyType = keyType
            self.usagePlanId = usagePlanId
        }

        public func encode(to encoder: Encoder) throws {
            let request = encoder.userInfo[.awsRequest]! as! RequestEncodingContainer
            var container = encoder.container(keyedBy: CodingKeys.self)
            try container.encode(self.keyId, forKey: .keyId)
            try container.encode(self.keyType, forKey: .keyType)
            request.encodePath(self.usagePlanId, key: "usagePlanId")
        }

        private enum CodingKeys: String, CodingKey {
            case keyId = "keyId"
            case keyType = "keyType"
        }
    }

    public struct CreateUsagePlanRequest: AWSEncodableShape {
        /// The associated API stages of the usage plan.
        public let apiStages: [ApiStage]?
        /// The description of the usage plan.
        public let description: String?
        /// The name of the usage plan.
        public let name: String
        /// The quota of the usage plan.
        public let quota: QuotaSettings?
        /// The key-value map of strings. The valid character set is [a-zA-Z+-=._:/]. The tag key can be up to 128 characters and must not start with aws:. The tag value can be up to 256 characters.
        public let tags: [String: String]?
        /// The throttling limits of the usage plan.
        public let throttle: ThrottleSettings?

        @inlinable
        public init(apiStages: [ApiStage]? = nil, description: String? = nil, name: String, quota: QuotaSettings? = nil, tags: [String: String]? = nil, throttle: ThrottleSettings? = nil) {
            self.apiStages = apiStages
            self.description = description
            self.name = name
            self.quota = quota
            self.tags = tags
            self.throttle = throttle
        }

        private enum CodingKeys: String, CodingKey {
            case apiStages = "apiStages"
            case description = "description"
            case name = "name"
            case quota = "quota"
            case tags = "tags"
            case throttle = "throttle"
        }
    }

    public struct CreateVpcLinkRequest: AWSEncodableShape {
        /// The description of the VPC link.
        public let description: String?
        /// The name used to label and identify the VPC link.
        public let name: String
        /// The key-value map of strings. The valid character set is [a-zA-Z+-=._:/]. The tag key can be up to 128 characters and must not start with aws:. The tag value can be up to 256 characters.
        public let tags: [String: String]?
        /// The ARN of the network load balancer of the VPC targeted by the VPC link. The network load balancer must be owned by the same Amazon Web Services account of the API owner.
        public let targetArns: [String]

        @inlinable
        public init(description: String? = nil, name: String, tags: [String: String]? = nil, targetArns: [String]) {
            self.description = description
            self.name = name
            self.tags = tags
            self.targetArns = targetArns
        }

        private enum CodingKeys: String, CodingKey {
            case description = "description"
            case name = "name"
            case tags = "tags"
            case targetArns = "targetArns"
        }
    }

    public struct DeleteApiKeyRequest: AWSEncodableShape {
        /// The identifier of the ApiKey resource to be deleted.
        public let apiKey: String

        @inlinable
        public init(apiKey: String) {
            self.apiKey = apiKey
        }

        public func encode(to encoder: Encoder) throws {
            let request = encoder.userInfo[.awsRequest]! as! RequestEncodingContainer
            _ = encoder.container(keyedBy: CodingKeys.self)
            request.encodePath(self.apiKey, key: "apiKey")
        }

        private enum CodingKeys: CodingKey {}
    }

    public struct DeleteAuthorizerRequest: AWSEncodableShape {
        /// The identifier of the Authorizer resource.
        public let authorizerId: String
        /// The string identifier of the associated RestApi.
        public let restApiId: String

        @inlinable
        public init(authorizerId: String, restApiId: String) {
            self.authorizerId = authorizerId
            self.restApiId = restApiId
        }

        public func encode(to encoder: Encoder) throws {
            let request = encoder.userInfo[.awsRequest]! as! RequestEncodingContainer
            _ = encoder.container(keyedBy: CodingKeys.self)
            request.encodePath(self.authorizerId, key: "authorizerId")
            request.encodePath(self.restApiId, key: "restApiId")
        }

        private enum CodingKeys: CodingKey {}
    }

    public struct DeleteBasePathMappingRequest: AWSEncodableShape {
        /// The base path name of the BasePathMapping resource to delete. To specify an empty base path, set this parameter to '(none)'.
        public let basePath: String
        /// The domain name of the BasePathMapping resource to delete.
        public let domainName: String
        ///  The identifier for the domain name resource. Supported only for private custom domain names.
        public let domainNameId: String?

        @inlinable
        public init(basePath: String, domainName: String, domainNameId: String? = nil) {
            self.basePath = basePath
            self.domainName = domainName
            self.domainNameId = domainNameId
        }

        public func encode(to encoder: Encoder) throws {
            let request = encoder.userInfo[.awsRequest]! as! RequestEncodingContainer
            _ = encoder.container(keyedBy: CodingKeys.self)
            request.encodePath(self.basePath, key: "basePath")
            request.encodePath(self.domainName, key: "domainName")
            request.encodeQuery(self.domainNameId, key: "domainNameId")
        }

        private enum CodingKeys: CodingKey {}
    }

    public struct DeleteClientCertificateRequest: AWSEncodableShape {
        /// The identifier of the ClientCertificate resource to be deleted.
        public let clientCertificateId: String

        @inlinable
        public init(clientCertificateId: String) {
            self.clientCertificateId = clientCertificateId
        }

        public func encode(to encoder: Encoder) throws {
            let request = encoder.userInfo[.awsRequest]! as! RequestEncodingContainer
            _ = encoder.container(keyedBy: CodingKeys.self)
            request.encodePath(self.clientCertificateId, key: "clientCertificateId")
        }

        private enum CodingKeys: CodingKey {}
    }

    public struct DeleteDeploymentRequest: AWSEncodableShape {
        /// The identifier of the Deployment resource to delete.
        public let deploymentId: String
        /// The string identifier of the associated RestApi.
        public let restApiId: String

        @inlinable
        public init(deploymentId: String, restApiId: String) {
            self.deploymentId = deploymentId
            self.restApiId = restApiId
        }

        public func encode(to encoder: Encoder) throws {
            let request = encoder.userInfo[.awsRequest]! as! RequestEncodingContainer
            _ = encoder.container(keyedBy: CodingKeys.self)
            request.encodePath(self.deploymentId, key: "deploymentId")
            request.encodePath(self.restApiId, key: "restApiId")
        }

        private enum CodingKeys: CodingKey {}
    }

    public struct DeleteDocumentationPartRequest: AWSEncodableShape {
        /// The identifier of the to-be-deleted documentation part.
        public let documentationPartId: String
        /// The string identifier of the associated RestApi.
        public let restApiId: String

        @inlinable
        public init(documentationPartId: String, restApiId: String) {
            self.documentationPartId = documentationPartId
            self.restApiId = restApiId
        }

        public func encode(to encoder: Encoder) throws {
            let request = encoder.userInfo[.awsRequest]! as! RequestEncodingContainer
            _ = encoder.container(keyedBy: CodingKeys.self)
            request.encodePath(self.documentationPartId, key: "documentationPartId")
            request.encodePath(self.restApiId, key: "restApiId")
        }

        private enum CodingKeys: CodingKey {}
    }

    public struct DeleteDocumentationVersionRequest: AWSEncodableShape {
        /// The version identifier of a to-be-deleted documentation snapshot.
        public let documentationVersion: String
        /// The string identifier of the associated RestApi.
        public let restApiId: String

        @inlinable
        public init(documentationVersion: String, restApiId: String) {
            self.documentationVersion = documentationVersion
            self.restApiId = restApiId
        }

        public func encode(to encoder: Encoder) throws {
            let request = encoder.userInfo[.awsRequest]! as! RequestEncodingContainer
            _ = encoder.container(keyedBy: CodingKeys.self)
            request.encodePath(self.documentationVersion, key: "documentationVersion")
            request.encodePath(self.restApiId, key: "restApiId")
        }

        private enum CodingKeys: CodingKey {}
    }

    public struct DeleteDomainNameAccessAssociationRequest: AWSEncodableShape {
        ///  The ARN of the domain name access association resource.
        public let domainNameAccessAssociationArn: String

        @inlinable
        public init(domainNameAccessAssociationArn: String) {
            self.domainNameAccessAssociationArn = domainNameAccessAssociationArn
        }

        public func encode(to encoder: Encoder) throws {
            let request = encoder.userInfo[.awsRequest]! as! RequestEncodingContainer
            _ = encoder.container(keyedBy: CodingKeys.self)
            request.encodePath(self.domainNameAccessAssociationArn, key: "domainNameAccessAssociationArn")
        }

        private enum CodingKeys: CodingKey {}
    }

    public struct DeleteDomainNameRequest: AWSEncodableShape {
        /// The name of the DomainName resource to be deleted.
        public let domainName: String
        ///  The identifier for the domain name resource. Supported only for private custom domain names.
        public let domainNameId: String?

        @inlinable
        public init(domainName: String, domainNameId: String? = nil) {
            self.domainName = domainName
            self.domainNameId = domainNameId
        }

        public func encode(to encoder: Encoder) throws {
            let request = encoder.userInfo[.awsRequest]! as! RequestEncodingContainer
            _ = encoder.container(keyedBy: CodingKeys.self)
            request.encodePath(self.domainName, key: "domainName")
            request.encodeQuery(self.domainNameId, key: "domainNameId")
        }

        private enum CodingKeys: CodingKey {}
    }

    public struct DeleteGatewayResponseRequest: AWSEncodableShape {
        /// The response type of the associated GatewayResponse.
        public let responseType: GatewayResponseType
        /// The string identifier of the associated RestApi.
        public let restApiId: String

        @inlinable
        public init(responseType: GatewayResponseType, restApiId: String) {
            self.responseType = responseType
            self.restApiId = restApiId
        }

        public func encode(to encoder: Encoder) throws {
            let request = encoder.userInfo[.awsRequest]! as! RequestEncodingContainer
            _ = encoder.container(keyedBy: CodingKeys.self)
            request.encodePath(self.responseType, key: "responseType")
            request.encodePath(self.restApiId, key: "restApiId")
        }

        private enum CodingKeys: CodingKey {}
    }

    public struct DeleteIntegrationRequest: AWSEncodableShape {
        /// Specifies a delete integration request's HTTP method.
        public let httpMethod: String
        /// Specifies a delete integration request's resource identifier.
        public let resourceId: String
        /// The string identifier of the associated RestApi.
        public let restApiId: String

        @inlinable
        public init(httpMethod: String, resourceId: String, restApiId: String) {
            self.httpMethod = httpMethod
            self.resourceId = resourceId
            self.restApiId = restApiId
        }

        public func encode(to encoder: Encoder) throws {
            let request = encoder.userInfo[.awsRequest]! as! RequestEncodingContainer
            _ = encoder.container(keyedBy: CodingKeys.self)
            request.encodePath(self.httpMethod, key: "httpMethod")
            request.encodePath(self.resourceId, key: "resourceId")
            request.encodePath(self.restApiId, key: "restApiId")
        }

        private enum CodingKeys: CodingKey {}
    }

    public struct DeleteIntegrationResponseRequest: AWSEncodableShape {
        /// Specifies a delete integration response request's HTTP method.
        public let httpMethod: String
        /// Specifies a delete integration response request's resource identifier.
        public let resourceId: String
        /// The string identifier of the associated RestApi.
        public let restApiId: String
        /// Specifies a delete integration response request's status code.
        public let statusCode: String

        @inlinable
        public init(httpMethod: String, resourceId: String, restApiId: String, statusCode: String) {
            self.httpMethod = httpMethod
            self.resourceId = resourceId
            self.restApiId = restApiId
            self.statusCode = statusCode
        }

        public func encode(to encoder: Encoder) throws {
            let request = encoder.userInfo[.awsRequest]! as! RequestEncodingContainer
            _ = encoder.container(keyedBy: CodingKeys.self)
            request.encodePath(self.httpMethod, key: "httpMethod")
            request.encodePath(self.resourceId, key: "resourceId")
            request.encodePath(self.restApiId, key: "restApiId")
            request.encodePath(self.statusCode, key: "statusCode")
        }

        public func validate(name: String) throws {
            try self.validate(self.statusCode, name: "statusCode", parent: name, pattern: "^[1-5]\\d\\d$")
        }

        private enum CodingKeys: CodingKey {}
    }

    public struct DeleteMethodRequest: AWSEncodableShape {
        /// The HTTP verb of the Method resource.
        public let httpMethod: String
        /// The Resource identifier for the Method resource.
        public let resourceId: String
        /// The string identifier of the associated RestApi.
        public let restApiId: String

        @inlinable
        public init(httpMethod: String, resourceId: String, restApiId: String) {
            self.httpMethod = httpMethod
            self.resourceId = resourceId
            self.restApiId = restApiId
        }

        public func encode(to encoder: Encoder) throws {
            let request = encoder.userInfo[.awsRequest]! as! RequestEncodingContainer
            _ = encoder.container(keyedBy: CodingKeys.self)
            request.encodePath(self.httpMethod, key: "httpMethod")
            request.encodePath(self.resourceId, key: "resourceId")
            request.encodePath(self.restApiId, key: "restApiId")
        }

        private enum CodingKeys: CodingKey {}
    }

    public struct DeleteMethodResponseRequest: AWSEncodableShape {
        /// The HTTP verb of the Method resource.
        public let httpMethod: String
        /// The Resource identifier for the MethodResponse resource.
        public let resourceId: String
        /// The string identifier of the associated RestApi.
        public let restApiId: String
        /// The status code identifier for the MethodResponse resource.
        public let statusCode: String

        @inlinable
        public init(httpMethod: String, resourceId: String, restApiId: String, statusCode: String) {
            self.httpMethod = httpMethod
            self.resourceId = resourceId
            self.restApiId = restApiId
            self.statusCode = statusCode
        }

        public func encode(to encoder: Encoder) throws {
            let request = encoder.userInfo[.awsRequest]! as! RequestEncodingContainer
            _ = encoder.container(keyedBy: CodingKeys.self)
            request.encodePath(self.httpMethod, key: "httpMethod")
            request.encodePath(self.resourceId, key: "resourceId")
            request.encodePath(self.restApiId, key: "restApiId")
            request.encodePath(self.statusCode, key: "statusCode")
        }

        public func validate(name: String) throws {
            try self.validate(self.statusCode, name: "statusCode", parent: name, pattern: "^[1-5]\\d\\d$")
        }

        private enum CodingKeys: CodingKey {}
    }

    public struct DeleteModelRequest: AWSEncodableShape {
        /// The name of the model to delete.
        public let modelName: String
        /// The string identifier of the associated RestApi.
        public let restApiId: String

        @inlinable
        public init(modelName: String, restApiId: String) {
            self.modelName = modelName
            self.restApiId = restApiId
        }

        public func encode(to encoder: Encoder) throws {
            let request = encoder.userInfo[.awsRequest]! as! RequestEncodingContainer
            _ = encoder.container(keyedBy: CodingKeys.self)
            request.encodePath(self.modelName, key: "modelName")
            request.encodePath(self.restApiId, key: "restApiId")
        }

        private enum CodingKeys: CodingKey {}
    }

    public struct DeleteRequestValidatorRequest: AWSEncodableShape {
        /// The identifier of the RequestValidator to be deleted.
        public let requestValidatorId: String
        /// The string identifier of the associated RestApi.
        public let restApiId: String

        @inlinable
        public init(requestValidatorId: String, restApiId: String) {
            self.requestValidatorId = requestValidatorId
            self.restApiId = restApiId
        }

        public func encode(to encoder: Encoder) throws {
            let request = encoder.userInfo[.awsRequest]! as! RequestEncodingContainer
            _ = encoder.container(keyedBy: CodingKeys.self)
            request.encodePath(self.requestValidatorId, key: "requestValidatorId")
            request.encodePath(self.restApiId, key: "restApiId")
        }

        private enum CodingKeys: CodingKey {}
    }

    public struct DeleteResourceRequest: AWSEncodableShape {
        /// The identifier of the Resource resource.
        public let resourceId: String
        /// The string identifier of the associated RestApi.
        public let restApiId: String

        @inlinable
        public init(resourceId: String, restApiId: String) {
            self.resourceId = resourceId
            self.restApiId = restApiId
        }

        public func encode(to encoder: Encoder) throws {
            let request = encoder.userInfo[.awsRequest]! as! RequestEncodingContainer
            _ = encoder.container(keyedBy: CodingKeys.self)
            request.encodePath(self.resourceId, key: "resourceId")
            request.encodePath(self.restApiId, key: "restApiId")
        }

        private enum CodingKeys: CodingKey {}
    }

    public struct DeleteRestApiRequest: AWSEncodableShape {
        /// The string identifier of the associated RestApi.
        public let restApiId: String

        @inlinable
        public init(restApiId: String) {
            self.restApiId = restApiId
        }

        public func encode(to encoder: Encoder) throws {
            let request = encoder.userInfo[.awsRequest]! as! RequestEncodingContainer
            _ = encoder.container(keyedBy: CodingKeys.self)
            request.encodePath(self.restApiId, key: "restApiId")
        }

        private enum CodingKeys: CodingKey {}
    }

    public struct DeleteStageRequest: AWSEncodableShape {
        /// The string identifier of the associated RestApi.
        public let restApiId: String
        /// The name of the Stage resource to delete.
        public let stageName: String

        @inlinable
        public init(restApiId: String, stageName: String) {
            self.restApiId = restApiId
            self.stageName = stageName
        }

        public func encode(to encoder: Encoder) throws {
            let request = encoder.userInfo[.awsRequest]! as! RequestEncodingContainer
            _ = encoder.container(keyedBy: CodingKeys.self)
            request.encodePath(self.restApiId, key: "restApiId")
            request.encodePath(self.stageName, key: "stageName")
        }

        private enum CodingKeys: CodingKey {}
    }

    public struct DeleteUsagePlanKeyRequest: AWSEncodableShape {
        /// The Id of the UsagePlanKey resource to be deleted.
        public let keyId: String
        /// The Id of the UsagePlan resource representing the usage plan containing the to-be-deleted UsagePlanKey resource representing a plan customer.
        public let usagePlanId: String

        @inlinable
        public init(keyId: String, usagePlanId: String) {
            self.keyId = keyId
            self.usagePlanId = usagePlanId
        }

        public func encode(to encoder: Encoder) throws {
            let request = encoder.userInfo[.awsRequest]! as! RequestEncodingContainer
            _ = encoder.container(keyedBy: CodingKeys.self)
            request.encodePath(self.keyId, key: "keyId")
            request.encodePath(self.usagePlanId, key: "usagePlanId")
        }

        private enum CodingKeys: CodingKey {}
    }

    public struct DeleteUsagePlanRequest: AWSEncodableShape {
        /// The Id of the to-be-deleted usage plan.
        public let usagePlanId: String

        @inlinable
        public init(usagePlanId: String) {
            self.usagePlanId = usagePlanId
        }

        public func encode(to encoder: Encoder) throws {
            let request = encoder.userInfo[.awsRequest]! as! RequestEncodingContainer
            _ = encoder.container(keyedBy: CodingKeys.self)
            request.encodePath(self.usagePlanId, key: "usagePlanId")
        }

        private enum CodingKeys: CodingKey {}
    }

    public struct DeleteVpcLinkRequest: AWSEncodableShape {
        /// The identifier of the  VpcLink. It is used in an Integration to reference this VpcLink.
        public let vpcLinkId: String

        @inlinable
        public init(vpcLinkId: String) {
            self.vpcLinkId = vpcLinkId
        }

        public func encode(to encoder: Encoder) throws {
            let request = encoder.userInfo[.awsRequest]! as! RequestEncodingContainer
            _ = encoder.container(keyedBy: CodingKeys.self)
            request.encodePath(self.vpcLinkId, key: "vpcLinkId")
        }

        private enum CodingKeys: CodingKey {}
    }

    public struct Deployment: AWSDecodableShape {
        /// A summary of the RestApi at the date and time that the deployment resource was created.
        public let apiSummary: [String: [String: MethodSnapshot]]?
        /// The date and time that the deployment resource was created.
        public let createdDate: Date?
        /// The description for the deployment resource.
        public let description: String?
        /// The identifier for the deployment resource.
        public let id: String?

        @inlinable
        public init(apiSummary: [String: [String: MethodSnapshot]]? = nil, createdDate: Date? = nil, description: String? = nil, id: String? = nil) {
            self.apiSummary = apiSummary
            self.createdDate = createdDate
            self.description = description
            self.id = id
        }

        private enum CodingKeys: String, CodingKey {
            case apiSummary = "apiSummary"
            case createdDate = "createdDate"
            case description = "description"
            case id = "id"
        }
    }

    public struct DeploymentCanarySettings: AWSEncodableShape {
        /// The percentage (0.0-100.0) of traffic routed to the canary deployment.
        public let percentTraffic: Double?
        /// A stage variable overrides used for the canary release deployment. They can override existing stage variables or add new stage variables for the canary release deployment. These stage variables are represented as a string-to-string map between stage variable names and their values.
        public let stageVariableOverrides: [String: String]?
        /// A Boolean flag to indicate whether the canary release deployment uses the stage cache or not.
        public let useStageCache: Bool?

        @inlinable
        public init(percentTraffic: Double? = nil, stageVariableOverrides: [String: String]? = nil, useStageCache: Bool? = nil) {
            self.percentTraffic = percentTraffic
            self.stageVariableOverrides = stageVariableOverrides
            self.useStageCache = useStageCache
        }

        private enum CodingKeys: String, CodingKey {
            case percentTraffic = "percentTraffic"
            case stageVariableOverrides = "stageVariableOverrides"
            case useStageCache = "useStageCache"
        }
    }

    public struct Deployments: AWSDecodableShape {
        /// The current page of elements from this collection.
        public let items: [Deployment]?
        /// The current pagination position in the paged result set.
        public let position: String?

        @inlinable
        public init(items: [Deployment]? = nil, position: String? = nil) {
            self.items = items
            self.position = position
        }

        private enum CodingKeys: String, CodingKey {
            case items = "item"
            case position = "position"
        }
    }

    public struct DocumentationPart: AWSDecodableShape {
        /// The DocumentationPart identifier, generated by API Gateway when the DocumentationPart is created.
        public let id: String?
        /// The location of the API entity to which the documentation applies. Valid fields depend on the targeted API entity type. All the valid location fields are not required. If not explicitly specified, a valid location field is treated as a wildcard and associated documentation content may be inherited by matching entities, unless overridden.
        public let location: DocumentationPartLocation?
        /// A content map of API-specific key-value pairs describing the targeted API entity. The map must be encoded as a JSON string, e.g., "{ \"description\": \"The API does ...\" }".  Only OpenAPI-compliant documentation-related fields from the properties map are exported and, hence, published as part of the API entity definitions, while the original documentation parts are exported in a OpenAPI extension of x-amazon-apigateway-documentation.
        public let properties: String?

        @inlinable
        public init(id: String? = nil, location: DocumentationPartLocation? = nil, properties: String? = nil) {
            self.id = id
            self.location = location
            self.properties = properties
        }

        private enum CodingKeys: String, CodingKey {
            case id = "id"
            case location = "location"
            case properties = "properties"
        }
    }

    public struct DocumentationPartIds: AWSDecodableShape {
        /// A list of the returned documentation part identifiers.
        public let ids: [String]?
        /// A list of warning messages reported during import of documentation parts.
        public let warnings: [String]?

        @inlinable
        public init(ids: [String]? = nil, warnings: [String]? = nil) {
            self.ids = ids
            self.warnings = warnings
        }

        private enum CodingKeys: String, CodingKey {
            case ids = "ids"
            case warnings = "warnings"
        }
    }

    public struct DocumentationPartLocation: AWSEncodableShape & AWSDecodableShape {
        /// The HTTP verb of a method. It is a valid field for the API entity types of  METHOD, PATH_PARAMETER, QUERY_PARAMETER, REQUEST_HEADER,  REQUEST_BODY, RESPONSE, RESPONSE_HEADER, and RESPONSE_BODY. The default value is * for any method.  When an applicable child entity inherits the content of an entity of the same type with more general specifications of the other location attributes,  the child entity's method attribute must match that of the parent entity exactly.
        public let method: String?
        /// The name of the targeted API entity. It is a valid and required field for the API entity types of AUTHORIZER, MODEL, PATH_PARAMETER, QUERY_PARAMETER, REQUEST_HEADER, REQUEST_BODY and RESPONSE_HEADER. It is an invalid field for any other entity type.
        public let name: String?
        /// The URL path of the target. It is a valid field for the API entity types of RESOURCE, METHOD, PATH_PARAMETER, QUERY_PARAMETER, REQUEST_HEADER, REQUEST_BODY, RESPONSE, RESPONSE_HEADER, and RESPONSE_BODY. The default value is / for the root resource. When an applicable child entity inherits the content of another entity of the same type with more general specifications of the other location attributes,  the child entity's path attribute must match that of the parent entity as a prefix.
        public let path: String?
        /// The HTTP status code of a response. It is a valid field for the API entity types of RESPONSE, RESPONSE_HEADER, and RESPONSE_BODY. The default value is * for any status code. When an applicable child  entity inherits the content of an entity of the same type with more general specifications of the other location attributes, the child entity's statusCode attribute must match that of the parent entity exactly.
        public let statusCode: String?
        /// The type of API entity to which the documentation content applies. Valid values are API, AUTHORIZER, MODEL, RESOURCE, METHOD, PATH_PARAMETER, QUERY_PARAMETER, REQUEST_HEADER,  REQUEST_BODY, RESPONSE, RESPONSE_HEADER, and RESPONSE_BODY. Content inheritance does not apply to any entity of the API, AUTHORIZER, METHOD,  MODEL, REQUEST_BODY, or RESOURCE type.
        public let type: DocumentationPartType

        @inlinable
        public init(method: String? = nil, name: String? = nil, path: String? = nil, statusCode: String? = nil, type: DocumentationPartType) {
            self.method = method
            self.name = name
            self.path = path
            self.statusCode = statusCode
            self.type = type
        }

        public func validate(name: String) throws {
            try self.validate(self.statusCode, name: "statusCode", parent: name, pattern: "^([1-5]\\d\\d|\\*|\\s*)$")
        }

        private enum CodingKeys: String, CodingKey {
            case method = "method"
            case name = "name"
            case path = "path"
            case statusCode = "statusCode"
            case type = "type"
        }
    }

    public struct DocumentationParts: AWSDecodableShape {
        /// The current page of elements from this collection.
        public let items: [DocumentationPart]?
        /// The current pagination position in the paged result set.
        public let position: String?

        @inlinable
        public init(items: [DocumentationPart]? = nil, position: String? = nil) {
            self.items = items
            self.position = position
        }

        private enum CodingKeys: String, CodingKey {
            case items = "item"
            case position = "position"
        }
    }

    public struct DocumentationVersion: AWSDecodableShape {
        /// The date when the API documentation snapshot is created.
        public let createdDate: Date?
        /// The description of the API documentation snapshot.
        public let description: String?
        /// The version identifier of the API documentation snapshot.
        public let version: String?

        @inlinable
        public init(createdDate: Date? = nil, description: String? = nil, version: String? = nil) {
            self.createdDate = createdDate
            self.description = description
            self.version = version
        }

        private enum CodingKeys: String, CodingKey {
            case createdDate = "createdDate"
            case description = "description"
            case version = "version"
        }
    }

    public struct DocumentationVersions: AWSDecodableShape {
        /// The current page of elements from this collection.
        public let items: [DocumentationVersion]?
        /// The current pagination position in the paged result set.
        public let position: String?

        @inlinable
        public init(items: [DocumentationVersion]? = nil, position: String? = nil) {
            self.items = items
            self.position = position
        }

        private enum CodingKeys: String, CodingKey {
            case items = "item"
            case position = "position"
        }
    }

    public struct DomainName: AWSDecodableShape {
        /// The reference to an Amazon Web Services-managed certificate that will be used by edge-optimized endpoint or private endpoint for this domain name. Certificate Manager is the only supported source.
        public let certificateArn: String?
        /// The name of the certificate that will be used by edge-optimized endpoint or private endpoint for this domain name.
        public let certificateName: String?
        /// The timestamp when the certificate that was used by edge-optimized endpoint or private endpoint for this domain name was uploaded.
        public let certificateUploadDate: Date?
        /// The domain name of the Amazon CloudFront distribution associated with this custom domain name for an edge-optimized endpoint. You set up this association when adding a DNS record pointing the custom domain name to this distribution name. For more information about CloudFront distributions, see the Amazon CloudFront documentation.
        public let distributionDomainName: String?
        /// The region-agnostic Amazon Route 53 Hosted Zone ID of the edge-optimized endpoint. The valid value is Z2FDTNDATAQYW2 for all the regions. For more information, see Set up a Regional Custom Domain Name and AWS Regions and Endpoints for API Gateway.
        public let distributionHostedZoneId: String?
        /// The custom domain name as an API host name, for example, my-api.example.com.
        public let domainName: String?
        /// The ARN of the domain name.
        public let domainNameArn: String?
        /// The identifier for the domain name resource. Supported only for private custom domain names.
        public let domainNameId: String?
        /// The status of the DomainName migration. The valid values are AVAILABLE and UPDATING. If the status is UPDATING, the domain cannot be modified further until the existing operation is complete. If it is AVAILABLE, the domain can be updated.
        public let domainNameStatus: DomainNameStatus?
        /// An optional text message containing detailed information about status of the DomainName migration.
        public let domainNameStatusMessage: String?
        /// The endpoint configuration of this DomainName showing the endpoint types and IP address types of the domain name.
        public let endpointConfiguration: EndpointConfiguration?
        /// A stringified JSON policy document that applies to the API Gateway Management service for this DomainName. This policy document controls access for access association sources to create domain name access associations with this DomainName. Supported only for private custom domain names.
        public let managementPolicy: String?
        /// The mutual TLS authentication configuration for a custom domain name. If specified, API Gateway performs two-way authentication between the client and the server. Clients must present a trusted certificate to access your API.
        public let mutualTlsAuthentication: MutualTlsAuthentication?
        /// The ARN of the public certificate issued by ACM to validate ownership of your custom domain. Only required when configuring mutual TLS and using an ACM imported or private CA certificate ARN as the regionalCertificateArn.
        public let ownershipVerificationCertificateArn: String?
        /// A stringified JSON policy document that applies to the execute-api service for this DomainName regardless of the caller and Method configuration. Supported only for private custom domain names.
        public let policy: String?
        /// The reference to an Amazon Web Services-managed certificate that will be used for validating the regional domain name. Certificate Manager is the only supported source.
        public let regionalCertificateArn: String?
        /// The name of the certificate that will be used for validating the regional domain name.
        public let regionalCertificateName: String?
        /// The domain name associated with the regional endpoint for this custom domain name. You set up this association by adding a DNS record that points the custom domain name to this regional domain name. The regional domain name is returned by API Gateway when you create a regional endpoint.
        public let regionalDomainName: String?
        /// The region-specific Amazon Route 53 Hosted Zone ID of the regional endpoint. For more information, see Set up a Regional Custom Domain Name and AWS Regions and Endpoints for API Gateway.
        public let regionalHostedZoneId: String?
        /// The routing mode for this domain name. The routing mode determines how API Gateway sends traffic from your custom domain name to your private APIs.
        public let routingMode: RoutingMode?
        /// The Transport Layer Security (TLS) version + cipher suite for this DomainName. The valid values are TLS_1_0 and TLS_1_2.
        public let securityPolicy: SecurityPolicy?
        /// The collection of tags. Each tag element is associated with a given resource.
        public let tags: [String: String]?

        @inlinable
        public init(certificateArn: String? = nil, certificateName: String? = nil, certificateUploadDate: Date? = nil, distributionDomainName: String? = nil, distributionHostedZoneId: String? = nil, domainName: String? = nil, domainNameArn: String? = nil, domainNameId: String? = nil, domainNameStatus: DomainNameStatus? = nil, domainNameStatusMessage: String? = nil, endpointConfiguration: EndpointConfiguration? = nil, managementPolicy: String? = nil, mutualTlsAuthentication: MutualTlsAuthentication? = nil, ownershipVerificationCertificateArn: String? = nil, policy: String? = nil, regionalCertificateArn: String? = nil, regionalCertificateName: String? = nil, regionalDomainName: String? = nil, regionalHostedZoneId: String? = nil, routingMode: RoutingMode? = nil, securityPolicy: SecurityPolicy? = nil, tags: [String: String]? = nil) {
            self.certificateArn = certificateArn
            self.certificateName = certificateName
            self.certificateUploadDate = certificateUploadDate
            self.distributionDomainName = distributionDomainName
            self.distributionHostedZoneId = distributionHostedZoneId
            self.domainName = domainName
            self.domainNameArn = domainNameArn
            self.domainNameId = domainNameId
            self.domainNameStatus = domainNameStatus
            self.domainNameStatusMessage = domainNameStatusMessage
            self.endpointConfiguration = endpointConfiguration
            self.managementPolicy = managementPolicy
            self.mutualTlsAuthentication = mutualTlsAuthentication
            self.ownershipVerificationCertificateArn = ownershipVerificationCertificateArn
            self.policy = policy
            self.regionalCertificateArn = regionalCertificateArn
            self.regionalCertificateName = regionalCertificateName
            self.regionalDomainName = regionalDomainName
            self.regionalHostedZoneId = regionalHostedZoneId
            self.routingMode = routingMode
            self.securityPolicy = securityPolicy
            self.tags = tags
        }

        private enum CodingKeys: String, CodingKey {
            case certificateArn = "certificateArn"
            case certificateName = "certificateName"
            case certificateUploadDate = "certificateUploadDate"
            case distributionDomainName = "distributionDomainName"
            case distributionHostedZoneId = "distributionHostedZoneId"
            case domainName = "domainName"
            case domainNameArn = "domainNameArn"
            case domainNameId = "domainNameId"
            case domainNameStatus = "domainNameStatus"
            case domainNameStatusMessage = "domainNameStatusMessage"
            case endpointConfiguration = "endpointConfiguration"
            case managementPolicy = "managementPolicy"
            case mutualTlsAuthentication = "mutualTlsAuthentication"
            case ownershipVerificationCertificateArn = "ownershipVerificationCertificateArn"
            case policy = "policy"
            case regionalCertificateArn = "regionalCertificateArn"
            case regionalCertificateName = "regionalCertificateName"
            case regionalDomainName = "regionalDomainName"
            case regionalHostedZoneId = "regionalHostedZoneId"
            case routingMode = "routingMode"
            case securityPolicy = "securityPolicy"
            case tags = "tags"
        }
    }

    public struct DomainNameAccessAssociation: AWSDecodableShape {
        ///  The ARN of the domain name access association source. For a VPCE, the ARN must be a VPC endpoint.
        public let accessAssociationSource: String?
        ///  The type of the domain name access association source.
        public let accessAssociationSourceType: AccessAssociationSourceType?
        /// The ARN of the domain name access association resource.
        public let domainNameAccessAssociationArn: String?
        /// The ARN of the domain name.
        public let domainNameArn: String?
        /// The collection of tags. Each tag element is associated with a given resource.
        public let tags: [String: String]?

        @inlinable
        public init(accessAssociationSource: String? = nil, accessAssociationSourceType: AccessAssociationSourceType? = nil, domainNameAccessAssociationArn: String? = nil, domainNameArn: String? = nil, tags: [String: String]? = nil) {
            self.accessAssociationSource = accessAssociationSource
            self.accessAssociationSourceType = accessAssociationSourceType
            self.domainNameAccessAssociationArn = domainNameAccessAssociationArn
            self.domainNameArn = domainNameArn
            self.tags = tags
        }

        private enum CodingKeys: String, CodingKey {
            case accessAssociationSource = "accessAssociationSource"
            case accessAssociationSourceType = "accessAssociationSourceType"
            case domainNameAccessAssociationArn = "domainNameAccessAssociationArn"
            case domainNameArn = "domainNameArn"
            case tags = "tags"
        }
    }

    public struct DomainNameAccessAssociations: AWSDecodableShape {
        /// The current page of elements from this collection.
        public let items: [DomainNameAccessAssociation]?
        /// The current pagination position in the paged result set.
        public let position: String?

        @inlinable
        public init(items: [DomainNameAccessAssociation]? = nil, position: String? = nil) {
            self.items = items
            self.position = position
        }

        private enum CodingKeys: String, CodingKey {
            case items = "item"
            case position = "position"
        }
    }

    public struct DomainNames: AWSDecodableShape {
        /// The current page of elements from this collection.
        public let items: [DomainName]?
        /// The current pagination position in the paged result set.
        public let position: String?

        @inlinable
        public init(items: [DomainName]? = nil, position: String? = nil) {
            self.items = items
            self.position = position
        }

        private enum CodingKeys: String, CodingKey {
            case items = "item"
            case position = "position"
        }
    }

    public struct EndpointConfiguration: AWSEncodableShape & AWSDecodableShape {
        /// The IP address types that can invoke an API (RestApi) or a DomainName. Use ipv4 to allow only IPv4 addresses to invoke an API or DomainName, or use dualstack to allow both IPv4 and IPv6 addresses to invoke an API or a DomainName. For the PRIVATE endpoint type, only dualstack is supported.
        public let ipAddressType: IpAddressType?
        /// A list of endpoint types of an API (RestApi) or its custom domain name (DomainName). For an edge-optimized API and its custom domain name, the endpoint type is "EDGE". For a regional API and its custom domain name, the endpoint type is REGIONAL. For a private API, the endpoint type is PRIVATE.
        public let types: [EndpointType]?
        /// A list of VpcEndpointIds of an API (RestApi) against which to create Route53 ALIASes. It is only supported for PRIVATE endpoint type.
        public let vpcEndpointIds: [String]?

        @inlinable
        public init(ipAddressType: IpAddressType? = nil, types: [EndpointType]? = nil, vpcEndpointIds: [String]? = nil) {
            self.ipAddressType = ipAddressType
            self.types = types
            self.vpcEndpointIds = vpcEndpointIds
        }

        private enum CodingKeys: String, CodingKey {
            case ipAddressType = "ipAddressType"
            case types = "types"
            case vpcEndpointIds = "vpcEndpointIds"
        }
    }

    public struct ExportResponse: AWSDecodableShape {
        public static let _options: AWSShapeOptions = [.rawPayload]
        /// The binary blob response to GetExport, which contains the export.
        public let body: AWSHTTPBody
        /// The content-disposition header value in the HTTP response.
        public let contentDisposition: String?
        /// The content-type header value in the HTTP response. This will correspond to a valid 'accept' type in the request.
        public let contentType: String?

        @inlinable
        public init(body: AWSHTTPBody, contentDisposition: String? = nil, contentType: String? = nil) {
            self.body = body
            self.contentDisposition = contentDisposition
            self.contentType = contentType
        }

        public init(from decoder: Decoder) throws {
            let response = decoder.userInfo[.awsResponse]! as! ResponseDecodingContainer
            let container = try decoder.singleValueContainer()
            self.body = try container.decode(AWSHTTPBody.self)
            self.contentDisposition = try response.decodeHeaderIfPresent(String.self, key: "Content-Disposition")
            self.contentType = try response.decodeHeaderIfPresent(String.self, key: "Content-Type")
        }

        private enum CodingKeys: CodingKey {}
    }

    public struct FlushStageAuthorizersCacheRequest: AWSEncodableShape {
        /// The string identifier of the associated RestApi.
        public let restApiId: String
        /// The name of the stage to flush.
        public let stageName: String

        @inlinable
        public init(restApiId: String, stageName: String) {
            self.restApiId = restApiId
            self.stageName = stageName
        }

        public func encode(to encoder: Encoder) throws {
            let request = encoder.userInfo[.awsRequest]! as! RequestEncodingContainer
            _ = encoder.container(keyedBy: CodingKeys.self)
            request.encodePath(self.restApiId, key: "restApiId")
            request.encodePath(self.stageName, key: "stageName")
        }

        private enum CodingKeys: CodingKey {}
    }

    public struct FlushStageCacheRequest: AWSEncodableShape {
        /// The string identifier of the associated RestApi.
        public let restApiId: String
        /// The name of the stage to flush its cache.
        public let stageName: String

        @inlinable
        public init(restApiId: String, stageName: String) {
            self.restApiId = restApiId
            self.stageName = stageName
        }

        public func encode(to encoder: Encoder) throws {
            let request = encoder.userInfo[.awsRequest]! as! RequestEncodingContainer
            _ = encoder.container(keyedBy: CodingKeys.self)
            request.encodePath(self.restApiId, key: "restApiId")
            request.encodePath(self.stageName, key: "stageName")
        }

        private enum CodingKeys: CodingKey {}
    }

    public struct GatewayResponse: AWSDecodableShape {
        /// A Boolean flag to indicate whether this GatewayResponse is the default gateway response (true) or not (false). A default gateway response is one generated by API Gateway without any customization by an API developer.
        public let defaultResponse: Bool?
        /// Response parameters (paths, query strings and headers) of the GatewayResponse as a string-to-string map of key-value pairs.
        public let responseParameters: [String: String]?
        /// Response templates of the GatewayResponse as a string-to-string map of key-value pairs.
        public let responseTemplates: [String: String]?
        /// The response type of the associated GatewayResponse.
        public let responseType: GatewayResponseType?
        /// The HTTP status code for this GatewayResponse.
        public let statusCode: String?

        @inlinable
        public init(defaultResponse: Bool? = nil, responseParameters: [String: String]? = nil, responseTemplates: [String: String]? = nil, responseType: GatewayResponseType? = nil, statusCode: String? = nil) {
            self.defaultResponse = defaultResponse
            self.responseParameters = responseParameters
            self.responseTemplates = responseTemplates
            self.responseType = responseType
            self.statusCode = statusCode
        }

        private enum CodingKeys: String, CodingKey {
            case defaultResponse = "defaultResponse"
            case responseParameters = "responseParameters"
            case responseTemplates = "responseTemplates"
            case responseType = "responseType"
            case statusCode = "statusCode"
        }
    }

    public struct GatewayResponses: AWSDecodableShape {
        /// Returns the entire collection, because of no pagination support.
        public let items: [GatewayResponse]?
        /// The current pagination position in the paged result set. The GatewayResponse collection does not support pagination and the position does not apply here.
        public let position: String?

        @inlinable
        public init(items: [GatewayResponse]? = nil, position: String? = nil) {
            self.items = items
            self.position = position
        }

        private enum CodingKeys: String, CodingKey {
            case items = "item"
            case position = "position"
        }
    }

    public struct GenerateClientCertificateRequest: AWSEncodableShape {
        /// The description of the ClientCertificate.
        public let description: String?
        /// The key-value map of strings. The valid character set is [a-zA-Z+-=._:/]. The tag key can be up to 128 characters and must not start with aws:. The tag value can be up to 256 characters.
        public let tags: [String: String]?

        @inlinable
        public init(description: String? = nil, tags: [String: String]? = nil) {
            self.description = description
            self.tags = tags
        }

        private enum CodingKeys: String, CodingKey {
            case description = "description"
            case tags = "tags"
        }
    }

    public struct GetAccountRequest: AWSEncodableShape {
        public init() {}
    }

    public struct GetApiKeyRequest: AWSEncodableShape {
        /// The identifier of the ApiKey resource.
        public let apiKey: String
        /// A boolean flag to specify whether (true) or not (false) the result contains the key value.
        public let includeValue: Bool?

        @inlinable
        public init(apiKey: String, includeValue: Bool? = nil) {
            self.apiKey = apiKey
            self.includeValue = includeValue
        }

        public func encode(to encoder: Encoder) throws {
            let request = encoder.userInfo[.awsRequest]! as! RequestEncodingContainer
            _ = encoder.container(keyedBy: CodingKeys.self)
            request.encodePath(self.apiKey, key: "apiKey")
            request.encodeQuery(self.includeValue, key: "includeValue")
        }

        private enum CodingKeys: CodingKey {}
    }

    public struct GetApiKeysRequest: AWSEncodableShape {
        /// The identifier of a customer in Amazon Web Services Marketplace or an external system, such as a developer portal.
        public let customerId: String?
        /// A boolean flag to specify whether (true) or not (false) the result contains key values.
        public let includeValues: Bool?
        /// The maximum number of returned results per page. The default value is 25 and the maximum value is 500.
        public let limit: Int?
        /// The name of queried API keys.
        public let nameQuery: String?
        /// The current pagination position in the paged result set.
        public let position: String?

        @inlinable
        public init(customerId: String? = nil, includeValues: Bool? = nil, limit: Int? = nil, nameQuery: String? = nil, position: String? = nil) {
            self.customerId = customerId
            self.includeValues = includeValues
            self.limit = limit
            self.nameQuery = nameQuery
            self.position = position
        }

        public func encode(to encoder: Encoder) throws {
            let request = encoder.userInfo[.awsRequest]! as! RequestEncodingContainer
            _ = encoder.container(keyedBy: CodingKeys.self)
            request.encodeQuery(self.customerId, key: "customerId")
            request.encodeQuery(self.includeValues, key: "includeValues")
            request.encodeQuery(self.limit, key: "limit")
            request.encodeQuery(self.nameQuery, key: "name")
            request.encodeQuery(self.position, key: "position")
        }

        private enum CodingKeys: CodingKey {}
    }

    public struct GetAuthorizerRequest: AWSEncodableShape {
        /// The identifier of the Authorizer resource.
        public let authorizerId: String
        /// The string identifier of the associated RestApi.
        public let restApiId: String

        @inlinable
        public init(authorizerId: String, restApiId: String) {
            self.authorizerId = authorizerId
            self.restApiId = restApiId
        }

        public func encode(to encoder: Encoder) throws {
            let request = encoder.userInfo[.awsRequest]! as! RequestEncodingContainer
            _ = encoder.container(keyedBy: CodingKeys.self)
            request.encodePath(self.authorizerId, key: "authorizerId")
            request.encodePath(self.restApiId, key: "restApiId")
        }

        private enum CodingKeys: CodingKey {}
    }

    public struct GetAuthorizersRequest: AWSEncodableShape {
        /// The maximum number of returned results per page. The default value is 25 and the maximum value is 500.
        public let limit: Int?
        /// The current pagination position in the paged result set.
        public let position: String?
        /// The string identifier of the associated RestApi.
        public let restApiId: String

        @inlinable
        public init(limit: Int? = nil, position: String? = nil, restApiId: String) {
            self.limit = limit
            self.position = position
            self.restApiId = restApiId
        }

        public func encode(to encoder: Encoder) throws {
            let request = encoder.userInfo[.awsRequest]! as! RequestEncodingContainer
            _ = encoder.container(keyedBy: CodingKeys.self)
            request.encodeQuery(self.limit, key: "limit")
            request.encodeQuery(self.position, key: "position")
            request.encodePath(self.restApiId, key: "restApiId")
        }

        private enum CodingKeys: CodingKey {}
    }

    public struct GetBasePathMappingRequest: AWSEncodableShape {
        /// The base path name that callers of the API must provide as part of the URL after the domain name. This value must be unique for all of the mappings across a single API. Specify '(none)' if you do not want callers to specify any base path name after the domain name.
        public let basePath: String
        /// The domain name of the BasePathMapping resource to be described.
        public let domainName: String
        /// The identifier for the domain name resource. Supported only for private custom domain names.
        public let domainNameId: String?

        @inlinable
        public init(basePath: String, domainName: String, domainNameId: String? = nil) {
            self.basePath = basePath
            self.domainName = domainName
            self.domainNameId = domainNameId
        }

        public func encode(to encoder: Encoder) throws {
            let request = encoder.userInfo[.awsRequest]! as! RequestEncodingContainer
            _ = encoder.container(keyedBy: CodingKeys.self)
            request.encodePath(self.basePath, key: "basePath")
            request.encodePath(self.domainName, key: "domainName")
            request.encodeQuery(self.domainNameId, key: "domainNameId")
        }

        private enum CodingKeys: CodingKey {}
    }

    public struct GetBasePathMappingsRequest: AWSEncodableShape {
        /// The domain name of a BasePathMapping resource.
        public let domainName: String
        ///  The identifier for the domain name resource. Supported only for private custom domain names.
        public let domainNameId: String?
        /// The maximum number of returned results per page. The default value is 25 and the maximum value is 500.
        public let limit: Int?
        /// The current pagination position in the paged result set.
        public let position: String?

        @inlinable
        public init(domainName: String, domainNameId: String? = nil, limit: Int? = nil, position: String? = nil) {
            self.domainName = domainName
            self.domainNameId = domainNameId
            self.limit = limit
            self.position = position
        }

        public func encode(to encoder: Encoder) throws {
            let request = encoder.userInfo[.awsRequest]! as! RequestEncodingContainer
            _ = encoder.container(keyedBy: CodingKeys.self)
            request.encodePath(self.domainName, key: "domainName")
            request.encodeQuery(self.domainNameId, key: "domainNameId")
            request.encodeQuery(self.limit, key: "limit")
            request.encodeQuery(self.position, key: "position")
        }

        private enum CodingKeys: CodingKey {}
    }

    public struct GetClientCertificateRequest: AWSEncodableShape {
        /// The identifier of the ClientCertificate resource to be described.
        public let clientCertificateId: String

        @inlinable
        public init(clientCertificateId: String) {
            self.clientCertificateId = clientCertificateId
        }

        public func encode(to encoder: Encoder) throws {
            let request = encoder.userInfo[.awsRequest]! as! RequestEncodingContainer
            _ = encoder.container(keyedBy: CodingKeys.self)
            request.encodePath(self.clientCertificateId, key: "clientCertificateId")
        }

        private enum CodingKeys: CodingKey {}
    }

    public struct GetClientCertificatesRequest: AWSEncodableShape {
        /// The maximum number of returned results per page. The default value is 25 and the maximum value is 500.
        public let limit: Int?
        /// The current pagination position in the paged result set.
        public let position: String?

        @inlinable
        public init(limit: Int? = nil, position: String? = nil) {
            self.limit = limit
            self.position = position
        }

        public func encode(to encoder: Encoder) throws {
            let request = encoder.userInfo[.awsRequest]! as! RequestEncodingContainer
            _ = encoder.container(keyedBy: CodingKeys.self)
            request.encodeQuery(self.limit, key: "limit")
            request.encodeQuery(self.position, key: "position")
        }

        private enum CodingKeys: CodingKey {}
    }

    public struct GetDeploymentRequest: AWSEncodableShape {
        /// The identifier of the Deployment resource to get information about.
        public let deploymentId: String
        /// A query parameter to retrieve the specified embedded resources of the returned Deployment resource in the response. In a REST API call, this embed parameter value is a list of comma-separated strings, as in  GET /restapis/{restapi_id}/deployments/{deployment_id}?embed=var1,var2. The SDK and other platform-dependent libraries might use a different format for the list. Currently, this request supports only retrieval of the embedded API summary this way. Hence, the parameter value must be a single-valued list containing only the "apisummary" string.  For example, GET /restapis/{restapi_id}/deployments/{deployment_id}?embed=apisummary.
        public let embed: [String]?
        /// The string identifier of the associated RestApi.
        public let restApiId: String

        @inlinable
        public init(deploymentId: String, embed: [String]? = nil, restApiId: String) {
            self.deploymentId = deploymentId
            self.embed = embed
            self.restApiId = restApiId
        }

        public func encode(to encoder: Encoder) throws {
            let request = encoder.userInfo[.awsRequest]! as! RequestEncodingContainer
            _ = encoder.container(keyedBy: CodingKeys.self)
            request.encodePath(self.deploymentId, key: "deploymentId")
            request.encodeQuery(self.embed, key: "embed")
            request.encodePath(self.restApiId, key: "restApiId")
        }

        private enum CodingKeys: CodingKey {}
    }

    public struct GetDeploymentsRequest: AWSEncodableShape {
        /// The maximum number of returned results per page. The default value is 25 and the maximum value is 500.
        public let limit: Int?
        /// The current pagination position in the paged result set.
        public let position: String?
        /// The string identifier of the associated RestApi.
        public let restApiId: String

        @inlinable
        public init(limit: Int? = nil, position: String? = nil, restApiId: String) {
            self.limit = limit
            self.position = position
            self.restApiId = restApiId
        }

        public func encode(to encoder: Encoder) throws {
            let request = encoder.userInfo[.awsRequest]! as! RequestEncodingContainer
            _ = encoder.container(keyedBy: CodingKeys.self)
            request.encodeQuery(self.limit, key: "limit")
            request.encodeQuery(self.position, key: "position")
            request.encodePath(self.restApiId, key: "restApiId")
        }

        private enum CodingKeys: CodingKey {}
    }

    public struct GetDocumentationPartRequest: AWSEncodableShape {
        /// The string identifier of the associated RestApi.
        public let documentationPartId: String
        /// The string identifier of the associated RestApi.
        public let restApiId: String

        @inlinable
        public init(documentationPartId: String, restApiId: String) {
            self.documentationPartId = documentationPartId
            self.restApiId = restApiId
        }

        public func encode(to encoder: Encoder) throws {
            let request = encoder.userInfo[.awsRequest]! as! RequestEncodingContainer
            _ = encoder.container(keyedBy: CodingKeys.self)
            request.encodePath(self.documentationPartId, key: "documentationPartId")
            request.encodePath(self.restApiId, key: "restApiId")
        }

        private enum CodingKeys: CodingKey {}
    }

    public struct GetDocumentationPartsRequest: AWSEncodableShape {
        /// The maximum number of returned results per page. The default value is 25 and the maximum value is 500.
        public let limit: Int?
        /// The status of the API documentation parts to retrieve. Valid values are DOCUMENTED for retrieving DocumentationPart resources with content and UNDOCUMENTED for DocumentationPart resources without content.
        public let locationStatus: LocationStatusType?
        /// The name of API entities of the to-be-retrieved documentation parts.
        public let nameQuery: String?
        /// The path of API entities of the to-be-retrieved documentation parts.
        public let path: String?
        /// The current pagination position in the paged result set.
        public let position: String?
        /// The string identifier of the associated RestApi.
        public let restApiId: String
        /// The type of API entities of the to-be-retrieved documentation parts.
        public let type: DocumentationPartType?

        @inlinable
        public init(limit: Int? = nil, locationStatus: LocationStatusType? = nil, nameQuery: String? = nil, path: String? = nil, position: String? = nil, restApiId: String, type: DocumentationPartType? = nil) {
            self.limit = limit
            self.locationStatus = locationStatus
            self.nameQuery = nameQuery
            self.path = path
            self.position = position
            self.restApiId = restApiId
            self.type = type
        }

        public func encode(to encoder: Encoder) throws {
            let request = encoder.userInfo[.awsRequest]! as! RequestEncodingContainer
            _ = encoder.container(keyedBy: CodingKeys.self)
            request.encodeQuery(self.limit, key: "limit")
            request.encodeQuery(self.locationStatus, key: "locationStatus")
            request.encodeQuery(self.nameQuery, key: "name")
            request.encodeQuery(self.path, key: "path")
            request.encodeQuery(self.position, key: "position")
            request.encodePath(self.restApiId, key: "restApiId")
            request.encodeQuery(self.type, key: "type")
        }

        private enum CodingKeys: CodingKey {}
    }

    public struct GetDocumentationVersionRequest: AWSEncodableShape {
        /// The version identifier of the to-be-retrieved documentation snapshot.
        public let documentationVersion: String
        /// The string identifier of the associated RestApi.
        public let restApiId: String

        @inlinable
        public init(documentationVersion: String, restApiId: String) {
            self.documentationVersion = documentationVersion
            self.restApiId = restApiId
        }

        public func encode(to encoder: Encoder) throws {
            let request = encoder.userInfo[.awsRequest]! as! RequestEncodingContainer
            _ = encoder.container(keyedBy: CodingKeys.self)
            request.encodePath(self.documentationVersion, key: "documentationVersion")
            request.encodePath(self.restApiId, key: "restApiId")
        }

        private enum CodingKeys: CodingKey {}
    }

    public struct GetDocumentationVersionsRequest: AWSEncodableShape {
        /// The maximum number of returned results per page. The default value is 25 and the maximum value is 500.
        public let limit: Int?
        /// The current pagination position in the paged result set.
        public let position: String?
        /// The string identifier of the associated RestApi.
        public let restApiId: String

        @inlinable
        public init(limit: Int? = nil, position: String? = nil, restApiId: String) {
            self.limit = limit
            self.position = position
            self.restApiId = restApiId
        }

        public func encode(to encoder: Encoder) throws {
            let request = encoder.userInfo[.awsRequest]! as! RequestEncodingContainer
            _ = encoder.container(keyedBy: CodingKeys.self)
            request.encodeQuery(self.limit, key: "limit")
            request.encodeQuery(self.position, key: "position")
            request.encodePath(self.restApiId, key: "restApiId")
        }

        private enum CodingKeys: CodingKey {}
    }

    public struct GetDomainNameAccessAssociationsRequest: AWSEncodableShape {
        /// The maximum number of returned results per page. The default value is 25 and the maximum value is 500.
        public let limit: Int?
        /// The current pagination position in the paged result set.
        public let position: String?
        ///  The owner of the domain name access association. Use SELF to only list the domain name access associations owned by your own account. Use OTHER_ACCOUNTS to list the domain name access associations with your private custom domain names that are owned by other AWS accounts.
        public let resourceOwner: ResourceOwner?

        @inlinable
        public init(limit: Int? = nil, position: String? = nil, resourceOwner: ResourceOwner? = nil) {
            self.limit = limit
            self.position = position
            self.resourceOwner = resourceOwner
        }

        public func encode(to encoder: Encoder) throws {
            let request = encoder.userInfo[.awsRequest]! as! RequestEncodingContainer
            _ = encoder.container(keyedBy: CodingKeys.self)
            request.encodeQuery(self.limit, key: "limit")
            request.encodeQuery(self.position, key: "position")
            request.encodeQuery(self.resourceOwner, key: "resourceOwner")
        }

        private enum CodingKeys: CodingKey {}
    }

    public struct GetDomainNameRequest: AWSEncodableShape {
        /// The name of the DomainName resource.
        public let domainName: String
        ///  The identifier for the domain name resource. Required for private custom domain names.
        public let domainNameId: String?

        @inlinable
        public init(domainName: String, domainNameId: String? = nil) {
            self.domainName = domainName
            self.domainNameId = domainNameId
        }

        public func encode(to encoder: Encoder) throws {
            let request = encoder.userInfo[.awsRequest]! as! RequestEncodingContainer
            _ = encoder.container(keyedBy: CodingKeys.self)
            request.encodePath(self.domainName, key: "domainName")
            request.encodeQuery(self.domainNameId, key: "domainNameId")
        }

        private enum CodingKeys: CodingKey {}
    }

    public struct GetDomainNamesRequest: AWSEncodableShape {
        /// The maximum number of returned results per page. The default value is 25 and the maximum value is 500.
        public let limit: Int?
        /// The current pagination position in the paged result set.
        public let position: String?
        /// The owner of the domain name access association.
        public let resourceOwner: ResourceOwner?

        @inlinable
        public init(limit: Int? = nil, position: String? = nil, resourceOwner: ResourceOwner? = nil) {
            self.limit = limit
            self.position = position
            self.resourceOwner = resourceOwner
        }

        public func encode(to encoder: Encoder) throws {
            let request = encoder.userInfo[.awsRequest]! as! RequestEncodingContainer
            _ = encoder.container(keyedBy: CodingKeys.self)
            request.encodeQuery(self.limit, key: "limit")
            request.encodeQuery(self.position, key: "position")
            request.encodeQuery(self.resourceOwner, key: "resourceOwner")
        }

        private enum CodingKeys: CodingKey {}
    }

    public struct GetExportRequest: AWSEncodableShape {
        /// The content-type of the export, for example application/json. Currently application/json and application/yaml are supported for exportType ofoas30 and swagger. This should be specified in the Accept header for direct API requests.
        public let accepts: String?
        /// The type of export. Acceptable values are 'oas30' for OpenAPI 3.0.x and 'swagger' for Swagger/OpenAPI 2.0.
        public let exportType: String
        /// A key-value map of query string parameters that specify properties of the export, depending on the requested exportType. For exportType oas30 and swagger, any combination of the following parameters are supported: extensions='integrations' or extensions='apigateway' will export the API with x-amazon-apigateway-integration extensions. extensions='authorizers' will export the API with  x-amazon-apigateway-authorizer extensions. postman will export the API with Postman extensions, allowing for import to the Postman tool
        public let parameters: [String: String]?
        /// The string identifier of the associated RestApi.
        public let restApiId: String
        /// The name of the Stage that will be exported.
        public let stageName: String

        @inlinable
        public init(accepts: String? = nil, exportType: String, parameters: [String: String]? = nil, restApiId: String, stageName: String) {
            self.accepts = accepts
            self.exportType = exportType
            self.parameters = parameters
            self.restApiId = restApiId
            self.stageName = stageName
        }

        public func encode(to encoder: Encoder) throws {
            let request = encoder.userInfo[.awsRequest]! as! RequestEncodingContainer
            _ = encoder.container(keyedBy: CodingKeys.self)
            request.encodeHeader(self.accepts, key: "Accept")
            request.encodePath(self.exportType, key: "exportType")
            request.encodeQuery(self.parameters)
            request.encodePath(self.restApiId, key: "restApiId")
            request.encodePath(self.stageName, key: "stageName")
        }

        private enum CodingKeys: CodingKey {}
    }

    public struct GetGatewayResponseRequest: AWSEncodableShape {
        /// The response type of the associated GatewayResponse.
        public let responseType: GatewayResponseType
        /// The string identifier of the associated RestApi.
        public let restApiId: String

        @inlinable
        public init(responseType: GatewayResponseType, restApiId: String) {
            self.responseType = responseType
            self.restApiId = restApiId
        }

        public func encode(to encoder: Encoder) throws {
            let request = encoder.userInfo[.awsRequest]! as! RequestEncodingContainer
            _ = encoder.container(keyedBy: CodingKeys.self)
            request.encodePath(self.responseType, key: "responseType")
            request.encodePath(self.restApiId, key: "restApiId")
        }

        private enum CodingKeys: CodingKey {}
    }

    public struct GetGatewayResponsesRequest: AWSEncodableShape {
        /// The maximum number of returned results per page. The default value is 25 and the maximum value is 500. The GatewayResponses collection does not support pagination and the limit does not apply here.
        public let limit: Int?
        /// The current pagination position in the paged result set. The GatewayResponse collection does not support pagination and the position does not apply here.
        public let position: String?
        /// The string identifier of the associated RestApi.
        public let restApiId: String

        @inlinable
        public init(limit: Int? = nil, position: String? = nil, restApiId: String) {
            self.limit = limit
            self.position = position
            self.restApiId = restApiId
        }

        public func encode(to encoder: Encoder) throws {
            let request = encoder.userInfo[.awsRequest]! as! RequestEncodingContainer
            _ = encoder.container(keyedBy: CodingKeys.self)
            request.encodeQuery(self.limit, key: "limit")
            request.encodeQuery(self.position, key: "position")
            request.encodePath(self.restApiId, key: "restApiId")
        }

        private enum CodingKeys: CodingKey {}
    }

    public struct GetIntegrationRequest: AWSEncodableShape {
        /// Specifies a get integration request's HTTP method.
        public let httpMethod: String
        /// Specifies a get integration request's resource identifier
        public let resourceId: String
        /// The string identifier of the associated RestApi.
        public let restApiId: String

        @inlinable
        public init(httpMethod: String, resourceId: String, restApiId: String) {
            self.httpMethod = httpMethod
            self.resourceId = resourceId
            self.restApiId = restApiId
        }

        public func encode(to encoder: Encoder) throws {
            let request = encoder.userInfo[.awsRequest]! as! RequestEncodingContainer
            _ = encoder.container(keyedBy: CodingKeys.self)
            request.encodePath(self.httpMethod, key: "httpMethod")
            request.encodePath(self.resourceId, key: "resourceId")
            request.encodePath(self.restApiId, key: "restApiId")
        }

        private enum CodingKeys: CodingKey {}
    }

    public struct GetIntegrationResponseRequest: AWSEncodableShape {
        /// Specifies a get integration response request's HTTP method.
        public let httpMethod: String
        /// Specifies a get integration response request's resource identifier.
        public let resourceId: String
        /// The string identifier of the associated RestApi.
        public let restApiId: String
        /// Specifies a get integration response request's status code.
        public let statusCode: String

        @inlinable
        public init(httpMethod: String, resourceId: String, restApiId: String, statusCode: String) {
            self.httpMethod = httpMethod
            self.resourceId = resourceId
            self.restApiId = restApiId
            self.statusCode = statusCode
        }

        public func encode(to encoder: Encoder) throws {
            let request = encoder.userInfo[.awsRequest]! as! RequestEncodingContainer
            _ = encoder.container(keyedBy: CodingKeys.self)
            request.encodePath(self.httpMethod, key: "httpMethod")
            request.encodePath(self.resourceId, key: "resourceId")
            request.encodePath(self.restApiId, key: "restApiId")
            request.encodePath(self.statusCode, key: "statusCode")
        }

        public func validate(name: String) throws {
            try self.validate(self.statusCode, name: "statusCode", parent: name, pattern: "^[1-5]\\d\\d$")
        }

        private enum CodingKeys: CodingKey {}
    }

    public struct GetMethodRequest: AWSEncodableShape {
        /// Specifies the method request's HTTP method type.
        public let httpMethod: String
        /// The Resource identifier for the Method resource.
        public let resourceId: String
        /// The string identifier of the associated RestApi.
        public let restApiId: String

        @inlinable
        public init(httpMethod: String, resourceId: String, restApiId: String) {
            self.httpMethod = httpMethod
            self.resourceId = resourceId
            self.restApiId = restApiId
        }

        public func encode(to encoder: Encoder) throws {
            let request = encoder.userInfo[.awsRequest]! as! RequestEncodingContainer
            _ = encoder.container(keyedBy: CodingKeys.self)
            request.encodePath(self.httpMethod, key: "httpMethod")
            request.encodePath(self.resourceId, key: "resourceId")
            request.encodePath(self.restApiId, key: "restApiId")
        }

        private enum CodingKeys: CodingKey {}
    }

    public struct GetMethodResponseRequest: AWSEncodableShape {
        /// The HTTP verb of the Method resource.
        public let httpMethod: String
        /// The Resource identifier for the MethodResponse resource.
        public let resourceId: String
        /// The string identifier of the associated RestApi.
        public let restApiId: String
        /// The status code for the MethodResponse resource.
        public let statusCode: String

        @inlinable
        public init(httpMethod: String, resourceId: String, restApiId: String, statusCode: String) {
            self.httpMethod = httpMethod
            self.resourceId = resourceId
            self.restApiId = restApiId
            self.statusCode = statusCode
        }

        public func encode(to encoder: Encoder) throws {
            let request = encoder.userInfo[.awsRequest]! as! RequestEncodingContainer
            _ = encoder.container(keyedBy: CodingKeys.self)
            request.encodePath(self.httpMethod, key: "httpMethod")
            request.encodePath(self.resourceId, key: "resourceId")
            request.encodePath(self.restApiId, key: "restApiId")
            request.encodePath(self.statusCode, key: "statusCode")
        }

        public func validate(name: String) throws {
            try self.validate(self.statusCode, name: "statusCode", parent: name, pattern: "^[1-5]\\d\\d$")
        }

        private enum CodingKeys: CodingKey {}
    }

    public struct GetModelRequest: AWSEncodableShape {
        /// A query parameter of a Boolean value to resolve (true) all external model references and returns a flattened model schema or not (false) The default is false.
        public let flatten: Bool?
        /// The name of the model as an identifier.
        public let modelName: String
        /// The RestApi identifier under which the Model exists.
        public let restApiId: String

        @inlinable
        public init(flatten: Bool? = nil, modelName: String, restApiId: String) {
            self.flatten = flatten
            self.modelName = modelName
            self.restApiId = restApiId
        }

        public func encode(to encoder: Encoder) throws {
            let request = encoder.userInfo[.awsRequest]! as! RequestEncodingContainer
            _ = encoder.container(keyedBy: CodingKeys.self)
            request.encodeQuery(self.flatten, key: "flatten")
            request.encodePath(self.modelName, key: "modelName")
            request.encodePath(self.restApiId, key: "restApiId")
        }

        private enum CodingKeys: CodingKey {}
    }

    public struct GetModelTemplateRequest: AWSEncodableShape {
        /// The name of the model for which to generate a template.
        public let modelName: String
        /// The string identifier of the associated RestApi.
        public let restApiId: String

        @inlinable
        public init(modelName: String, restApiId: String) {
            self.modelName = modelName
            self.restApiId = restApiId
        }

        public func encode(to encoder: Encoder) throws {
            let request = encoder.userInfo[.awsRequest]! as! RequestEncodingContainer
            _ = encoder.container(keyedBy: CodingKeys.self)
            request.encodePath(self.modelName, key: "modelName")
            request.encodePath(self.restApiId, key: "restApiId")
        }

        private enum CodingKeys: CodingKey {}
    }

    public struct GetModelsRequest: AWSEncodableShape {
        /// The maximum number of returned results per page. The default value is 25 and the maximum value is 500.
        public let limit: Int?
        /// The current pagination position in the paged result set.
        public let position: String?
        /// The string identifier of the associated RestApi.
        public let restApiId: String

        @inlinable
        public init(limit: Int? = nil, position: String? = nil, restApiId: String) {
            self.limit = limit
            self.position = position
            self.restApiId = restApiId
        }

        public func encode(to encoder: Encoder) throws {
            let request = encoder.userInfo[.awsRequest]! as! RequestEncodingContainer
            _ = encoder.container(keyedBy: CodingKeys.self)
            request.encodeQuery(self.limit, key: "limit")
            request.encodeQuery(self.position, key: "position")
            request.encodePath(self.restApiId, key: "restApiId")
        }

        private enum CodingKeys: CodingKey {}
    }

    public struct GetRequestValidatorRequest: AWSEncodableShape {
        /// The identifier of the RequestValidator to be retrieved.
        public let requestValidatorId: String
        /// The string identifier of the associated RestApi.
        public let restApiId: String

        @inlinable
        public init(requestValidatorId: String, restApiId: String) {
            self.requestValidatorId = requestValidatorId
            self.restApiId = restApiId
        }

        public func encode(to encoder: Encoder) throws {
            let request = encoder.userInfo[.awsRequest]! as! RequestEncodingContainer
            _ = encoder.container(keyedBy: CodingKeys.self)
            request.encodePath(self.requestValidatorId, key: "requestValidatorId")
            request.encodePath(self.restApiId, key: "restApiId")
        }

        private enum CodingKeys: CodingKey {}
    }

    public struct GetRequestValidatorsRequest: AWSEncodableShape {
        /// The maximum number of returned results per page. The default value is 25 and the maximum value is 500.
        public let limit: Int?
        /// The current pagination position in the paged result set.
        public let position: String?
        /// The string identifier of the associated RestApi.
        public let restApiId: String

        @inlinable
        public init(limit: Int? = nil, position: String? = nil, restApiId: String) {
            self.limit = limit
            self.position = position
            self.restApiId = restApiId
        }

        public func encode(to encoder: Encoder) throws {
            let request = encoder.userInfo[.awsRequest]! as! RequestEncodingContainer
            _ = encoder.container(keyedBy: CodingKeys.self)
            request.encodeQuery(self.limit, key: "limit")
            request.encodeQuery(self.position, key: "position")
            request.encodePath(self.restApiId, key: "restApiId")
        }

        private enum CodingKeys: CodingKey {}
    }

    public struct GetResourceRequest: AWSEncodableShape {
        /// A query parameter to retrieve the specified resources embedded in the returned Resource representation in the response. This embed parameter value is a list of comma-separated strings. Currently, the request supports only retrieval of the embedded Method resources this way. The query parameter value must be a single-valued list and contain the "methods" string. For example, GET /restapis/{restapi_id}/resources/{resource_id}?embed=methods.
        public let embed: [String]?
        /// The identifier for the Resource resource.
        public let resourceId: String
        /// The string identifier of the associated RestApi.
        public let restApiId: String

        @inlinable
        public init(embed: [String]? = nil, resourceId: String, restApiId: String) {
            self.embed = embed
            self.resourceId = resourceId
            self.restApiId = restApiId
        }

        public func encode(to encoder: Encoder) throws {
            let request = encoder.userInfo[.awsRequest]! as! RequestEncodingContainer
            _ = encoder.container(keyedBy: CodingKeys.self)
            request.encodeQuery(self.embed, key: "embed")
            request.encodePath(self.resourceId, key: "resourceId")
            request.encodePath(self.restApiId, key: "restApiId")
        }

        private enum CodingKeys: CodingKey {}
    }

    public struct GetResourcesRequest: AWSEncodableShape {
        /// A query parameter used to retrieve the specified resources embedded in the returned Resources resource in the response.  This embed parameter value is a list of comma-separated strings. Currently, the request supports only retrieval of the embedded Method resources this way. The query parameter value must be a single-valued list and contain the "methods" string. For example, GET /restapis/{restapi_id}/resources?embed=methods.
        public let embed: [String]?
        /// The maximum number of returned results per page. The default value is 25 and the maximum value is 500.
        public let limit: Int?
        /// The current pagination position in the paged result set.
        public let position: String?
        /// The string identifier of the associated RestApi.
        public let restApiId: String

        @inlinable
        public init(embed: [String]? = nil, limit: Int? = nil, position: String? = nil, restApiId: String) {
            self.embed = embed
            self.limit = limit
            self.position = position
            self.restApiId = restApiId
        }

        public func encode(to encoder: Encoder) throws {
            let request = encoder.userInfo[.awsRequest]! as! RequestEncodingContainer
            _ = encoder.container(keyedBy: CodingKeys.self)
            request.encodeQuery(self.embed, key: "embed")
            request.encodeQuery(self.limit, key: "limit")
            request.encodeQuery(self.position, key: "position")
            request.encodePath(self.restApiId, key: "restApiId")
        }

        private enum CodingKeys: CodingKey {}
    }

    public struct GetRestApiRequest: AWSEncodableShape {
        /// The string identifier of the associated RestApi.
        public let restApiId: String

        @inlinable
        public init(restApiId: String) {
            self.restApiId = restApiId
        }

        public func encode(to encoder: Encoder) throws {
            let request = encoder.userInfo[.awsRequest]! as! RequestEncodingContainer
            _ = encoder.container(keyedBy: CodingKeys.self)
            request.encodePath(self.restApiId, key: "restApiId")
        }

        private enum CodingKeys: CodingKey {}
    }

    public struct GetRestApisRequest: AWSEncodableShape {
        /// The maximum number of returned results per page. The default value is 25 and the maximum value is 500.
        public let limit: Int?
        /// The current pagination position in the paged result set.
        public let position: String?

        @inlinable
        public init(limit: Int? = nil, position: String? = nil) {
            self.limit = limit
            self.position = position
        }

        public func encode(to encoder: Encoder) throws {
            let request = encoder.userInfo[.awsRequest]! as! RequestEncodingContainer
            _ = encoder.container(keyedBy: CodingKeys.self)
            request.encodeQuery(self.limit, key: "limit")
            request.encodeQuery(self.position, key: "position")
        }

        private enum CodingKeys: CodingKey {}
    }

    public struct GetSdkRequest: AWSEncodableShape {
        /// A string-to-string key-value map of query parameters sdkType-dependent properties of the SDK. For sdkType of objectivec or swift,  a parameter named classPrefix is required. For sdkType of android, parameters named groupId, artifactId, artifactVersion, and invokerPackage are required. For sdkType of java, parameters named serviceName and javaPackageName are required.
        public let parameters: [String: String]?
        /// The string identifier of the associated RestApi.
        public let restApiId: String
        /// The language for the generated SDK. Currently java, javascript, android, objectivec (for iOS), swift (for iOS), and ruby  are supported.
        public let sdkType: String
        /// The name of the Stage that the SDK will use.
        public let stageName: String

        @inlinable
        public init(parameters: [String: String]? = nil, restApiId: String, sdkType: String, stageName: String) {
            self.parameters = parameters
            self.restApiId = restApiId
            self.sdkType = sdkType
            self.stageName = stageName
        }

        public func encode(to encoder: Encoder) throws {
            let request = encoder.userInfo[.awsRequest]! as! RequestEncodingContainer
            _ = encoder.container(keyedBy: CodingKeys.self)
            request.encodeQuery(self.parameters)
            request.encodePath(self.restApiId, key: "restApiId")
            request.encodePath(self.sdkType, key: "sdkType")
            request.encodePath(self.stageName, key: "stageName")
        }

        private enum CodingKeys: CodingKey {}
    }

    public struct GetSdkTypeRequest: AWSEncodableShape {
        /// The identifier of the queried SdkType instance.
        public let id: String

        @inlinable
        public init(id: String) {
            self.id = id
        }

        public func encode(to encoder: Encoder) throws {
            let request = encoder.userInfo[.awsRequest]! as! RequestEncodingContainer
            _ = encoder.container(keyedBy: CodingKeys.self)
            request.encodePath(self.id, key: "id")
        }

        private enum CodingKeys: CodingKey {}
    }

    public struct GetSdkTypesRequest: AWSEncodableShape {
        /// The maximum number of returned results per page. The default value is 25 and the maximum value is 500.
        public let limit: Int?
        /// The current pagination position in the paged result set.
        public let position: String?

        @inlinable
        public init(limit: Int? = nil, position: String? = nil) {
            self.limit = limit
            self.position = position
        }

        public func encode(to encoder: Encoder) throws {
            let request = encoder.userInfo[.awsRequest]! as! RequestEncodingContainer
            _ = encoder.container(keyedBy: CodingKeys.self)
            request.encodeQuery(self.limit, key: "limit")
            request.encodeQuery(self.position, key: "position")
        }

        private enum CodingKeys: CodingKey {}
    }

    public struct GetStageRequest: AWSEncodableShape {
        /// The string identifier of the associated RestApi.
        public let restApiId: String
        /// The name of the Stage resource to get information about.
        public let stageName: String

        @inlinable
        public init(restApiId: String, stageName: String) {
            self.restApiId = restApiId
            self.stageName = stageName
        }

        public func encode(to encoder: Encoder) throws {
            let request = encoder.userInfo[.awsRequest]! as! RequestEncodingContainer
            _ = encoder.container(keyedBy: CodingKeys.self)
            request.encodePath(self.restApiId, key: "restApiId")
            request.encodePath(self.stageName, key: "stageName")
        }

        private enum CodingKeys: CodingKey {}
    }

    public struct GetStagesRequest: AWSEncodableShape {
        /// The stages' deployment identifiers.
        public let deploymentId: String?
        /// The string identifier of the associated RestApi.
        public let restApiId: String

        @inlinable
        public init(deploymentId: String? = nil, restApiId: String) {
            self.deploymentId = deploymentId
            self.restApiId = restApiId
        }

        public func encode(to encoder: Encoder) throws {
            let request = encoder.userInfo[.awsRequest]! as! RequestEncodingContainer
            _ = encoder.container(keyedBy: CodingKeys.self)
            request.encodeQuery(self.deploymentId, key: "deploymentId")
            request.encodePath(self.restApiId, key: "restApiId")
        }

        private enum CodingKeys: CodingKey {}
    }

    public struct GetTagsRequest: AWSEncodableShape {
        /// (Not currently supported) The maximum number of returned results per page. The default value is 25 and the maximum value is 500.
        public let limit: Int?
        /// (Not currently supported) The current pagination position in the paged result set.
        public let position: String?
        /// The ARN of a resource that can be tagged.
        public let resourceArn: String

        @inlinable
        public init(limit: Int? = nil, position: String? = nil, resourceArn: String) {
            self.limit = limit
            self.position = position
            self.resourceArn = resourceArn
        }

        public func encode(to encoder: Encoder) throws {
            let request = encoder.userInfo[.awsRequest]! as! RequestEncodingContainer
            _ = encoder.container(keyedBy: CodingKeys.self)
            request.encodeQuery(self.limit, key: "limit")
            request.encodeQuery(self.position, key: "position")
            request.encodePath(self.resourceArn, key: "resourceArn")
        }

        private enum CodingKeys: CodingKey {}
    }

    public struct GetUsagePlanKeyRequest: AWSEncodableShape {
        /// The key Id of the to-be-retrieved UsagePlanKey resource representing a plan customer.
        public let keyId: String
        /// The Id of the UsagePlan resource representing the usage plan containing the to-be-retrieved UsagePlanKey resource representing a plan customer.
        public let usagePlanId: String

        @inlinable
        public init(keyId: String, usagePlanId: String) {
            self.keyId = keyId
            self.usagePlanId = usagePlanId
        }

        public func encode(to encoder: Encoder) throws {
            let request = encoder.userInfo[.awsRequest]! as! RequestEncodingContainer
            _ = encoder.container(keyedBy: CodingKeys.self)
            request.encodePath(self.keyId, key: "keyId")
            request.encodePath(self.usagePlanId, key: "usagePlanId")
        }

        private enum CodingKeys: CodingKey {}
    }

    public struct GetUsagePlanKeysRequest: AWSEncodableShape {
        /// The maximum number of returned results per page. The default value is 25 and the maximum value is 500.
        public let limit: Int?
        /// A query parameter specifying the name of the to-be-returned usage plan keys.
        public let nameQuery: String?
        /// The current pagination position in the paged result set.
        public let position: String?
        /// The Id of the UsagePlan resource representing the usage plan containing the to-be-retrieved UsagePlanKey resource representing a plan customer.
        public let usagePlanId: String

        @inlinable
        public init(limit: Int? = nil, nameQuery: String? = nil, position: String? = nil, usagePlanId: String) {
            self.limit = limit
            self.nameQuery = nameQuery
            self.position = position
            self.usagePlanId = usagePlanId
        }

        public func encode(to encoder: Encoder) throws {
            let request = encoder.userInfo[.awsRequest]! as! RequestEncodingContainer
            _ = encoder.container(keyedBy: CodingKeys.self)
            request.encodeQuery(self.limit, key: "limit")
            request.encodeQuery(self.nameQuery, key: "name")
            request.encodeQuery(self.position, key: "position")
            request.encodePath(self.usagePlanId, key: "usagePlanId")
        }

        private enum CodingKeys: CodingKey {}
    }

    public struct GetUsagePlanRequest: AWSEncodableShape {
        /// The identifier of the UsagePlan resource to be retrieved.
        public let usagePlanId: String

        @inlinable
        public init(usagePlanId: String) {
            self.usagePlanId = usagePlanId
        }

        public func encode(to encoder: Encoder) throws {
            let request = encoder.userInfo[.awsRequest]! as! RequestEncodingContainer
            _ = encoder.container(keyedBy: CodingKeys.self)
            request.encodePath(self.usagePlanId, key: "usagePlanId")
        }

        private enum CodingKeys: CodingKey {}
    }

    public struct GetUsagePlansRequest: AWSEncodableShape {
        /// The identifier of the API key associated with the usage plans.
        public let keyId: String?
        /// The maximum number of returned results per page. The default value is 25 and the maximum value is 500.
        public let limit: Int?
        /// The current pagination position in the paged result set.
        public let position: String?

        @inlinable
        public init(keyId: String? = nil, limit: Int? = nil, position: String? = nil) {
            self.keyId = keyId
            self.limit = limit
            self.position = position
        }

        public func encode(to encoder: Encoder) throws {
            let request = encoder.userInfo[.awsRequest]! as! RequestEncodingContainer
            _ = encoder.container(keyedBy: CodingKeys.self)
            request.encodeQuery(self.keyId, key: "keyId")
            request.encodeQuery(self.limit, key: "limit")
            request.encodeQuery(self.position, key: "position")
        }

        private enum CodingKeys: CodingKey {}
    }

    public struct GetUsageRequest: AWSEncodableShape {
        /// The ending date (e.g., 2016-12-31) of the usage data.
        public let endDate: String
        /// The Id of the API key associated with the resultant usage data.
        public let keyId: String?
        /// The maximum number of returned results per page. The default value is 25 and the maximum value is 500.
        public let limit: Int?
        /// The current pagination position in the paged result set.
        public let position: String?
        /// The starting date (e.g., 2016-01-01) of the usage data.
        public let startDate: String
        /// The Id of the usage plan associated with the usage data.
        public let usagePlanId: String

        @inlinable
        public init(endDate: String, keyId: String? = nil, limit: Int? = nil, position: String? = nil, startDate: String, usagePlanId: String) {
            self.endDate = endDate
            self.keyId = keyId
            self.limit = limit
            self.position = position
            self.startDate = startDate
            self.usagePlanId = usagePlanId
        }

        public func encode(to encoder: Encoder) throws {
            let request = encoder.userInfo[.awsRequest]! as! RequestEncodingContainer
            _ = encoder.container(keyedBy: CodingKeys.self)
            request.encodeQuery(self.endDate, key: "endDate")
            request.encodeQuery(self.keyId, key: "keyId")
            request.encodeQuery(self.limit, key: "limit")
            request.encodeQuery(self.position, key: "position")
            request.encodeQuery(self.startDate, key: "startDate")
            request.encodePath(self.usagePlanId, key: "usagePlanId")
        }

        private enum CodingKeys: CodingKey {}
    }

    public struct GetVpcLinkRequest: AWSEncodableShape {
        /// The identifier of the  VpcLink. It is used in an Integration to reference this VpcLink.
        public let vpcLinkId: String

        @inlinable
        public init(vpcLinkId: String) {
            self.vpcLinkId = vpcLinkId
        }

        public func encode(to encoder: Encoder) throws {
            let request = encoder.userInfo[.awsRequest]! as! RequestEncodingContainer
            _ = encoder.container(keyedBy: CodingKeys.self)
            request.encodePath(self.vpcLinkId, key: "vpcLinkId")
        }

        private enum CodingKeys: CodingKey {}
    }

    public struct GetVpcLinksRequest: AWSEncodableShape {
        /// The maximum number of returned results per page. The default value is 25 and the maximum value is 500.
        public let limit: Int?
        /// The current pagination position in the paged result set.
        public let position: String?

        @inlinable
        public init(limit: Int? = nil, position: String? = nil) {
            self.limit = limit
            self.position = position
        }

        public func encode(to encoder: Encoder) throws {
            let request = encoder.userInfo[.awsRequest]! as! RequestEncodingContainer
            _ = encoder.container(keyedBy: CodingKeys.self)
            request.encodeQuery(self.limit, key: "limit")
            request.encodeQuery(self.position, key: "position")
        }

        private enum CodingKeys: CodingKey {}
    }

    public struct ImportApiKeysRequest: AWSEncodableShape {
        /// The payload of the POST request to import API keys. For the payload format, see API Key File Format.
        public let body: AWSHTTPBody
        /// A query parameter to indicate whether to rollback ApiKey importation (true) or not (false) when error is encountered.
        public let failOnWarnings: Bool?
        /// A query parameter to specify the input format to imported API keys. Currently, only the csv format is supported.
        public let format: ApiKeysFormat

        @inlinable
        public init(body: AWSHTTPBody, failOnWarnings: Bool? = nil, format: ApiKeysFormat) {
            self.body = body
            self.failOnWarnings = failOnWarnings
            self.format = format
        }

        public func encode(to encoder: Encoder) throws {
            let request = encoder.userInfo[.awsRequest]! as! RequestEncodingContainer
            var container = encoder.singleValueContainer()
            try container.encode(self.body)
            request.encodeQuery(self.failOnWarnings, key: "failonwarnings")
            request.encodeQuery(self.format, key: "format")
        }

        private enum CodingKeys: CodingKey {}
    }

    public struct ImportDocumentationPartsRequest: AWSEncodableShape {
        /// Raw byte array representing the to-be-imported documentation parts. To import from an OpenAPI file, this is a JSON object.
        public let body: AWSHTTPBody
        /// A query parameter to specify whether to rollback the documentation importation (true) or not (false) when a warning is encountered. The default value is false.
        public let failOnWarnings: Bool?
        /// A query parameter to indicate whether to overwrite (overwrite) any existing DocumentationParts definition or to merge (merge) the new definition into the existing one. The default value is merge.
        public let mode: PutMode?
        /// The string identifier of the associated RestApi.
        public let restApiId: String

        @inlinable
        public init(body: AWSHTTPBody, failOnWarnings: Bool? = nil, mode: PutMode? = nil, restApiId: String) {
            self.body = body
            self.failOnWarnings = failOnWarnings
            self.mode = mode
            self.restApiId = restApiId
        }

        public func encode(to encoder: Encoder) throws {
            let request = encoder.userInfo[.awsRequest]! as! RequestEncodingContainer
            var container = encoder.singleValueContainer()
            try container.encode(self.body)
            request.encodeQuery(self.failOnWarnings, key: "failonwarnings")
            request.encodeQuery(self.mode, key: "mode")
            request.encodePath(self.restApiId, key: "restApiId")
        }

        private enum CodingKeys: CodingKey {}
    }

    public struct ImportRestApiRequest: AWSEncodableShape {
        /// The POST request body containing external API definitions. Currently, only OpenAPI definition JSON/YAML files are supported. The maximum size of the API definition file is 6MB.
        public let body: AWSHTTPBody
        /// A query parameter to indicate whether to rollback the API creation (true) or not (false) when a warning is encountered. The default value is false.
        public let failOnWarnings: Bool?
        /// A key-value map of context-specific query string parameters specifying the behavior of different API importing operations. The following shows operation-specific parameters and their supported values. To exclude DocumentationParts from the import, set parameters as ignore=documentation. To configure the endpoint type, set parameters as endpointConfigurationTypes=EDGE, endpointConfigurationTypes=REGIONAL, or endpointConfigurationTypes=PRIVATE. The default endpoint type is EDGE. To handle imported basepath, set parameters as basepath=ignore, basepath=prepend or basepath=split.
        public let parameters: [String: String]?

        @inlinable
        public init(body: AWSHTTPBody, failOnWarnings: Bool? = nil, parameters: [String: String]? = nil) {
            self.body = body
            self.failOnWarnings = failOnWarnings
            self.parameters = parameters
        }

        public func encode(to encoder: Encoder) throws {
            let request = encoder.userInfo[.awsRequest]! as! RequestEncodingContainer
            var container = encoder.singleValueContainer()
            try container.encode(self.body)
            request.encodeQuery(self.failOnWarnings, key: "failonwarnings")
            request.encodeQuery(self.parameters)
        }

        private enum CodingKeys: CodingKey {}
    }

    public struct Integration: AWSDecodableShape {
        /// A list of request parameters whose values API Gateway caches. To be valid values for cacheKeyParameters, these parameters must also be specified for Method requestParameters.
        public let cacheKeyParameters: [String]?
        /// Specifies a group of related cached parameters. By default, API Gateway uses the resource ID as the cacheNamespace. You can specify the same cacheNamespace across resources to return the same cached data for requests to different resources.
        public let cacheNamespace: String?
        /// The ID of the VpcLink used for the integration when connectionType=VPC_LINK and undefined, otherwise.
        public let connectionId: String?
        /// The type of the network connection to the integration endpoint. The valid value is INTERNET for connections through the public routable internet or VPC_LINK for private connections between API Gateway and a network load balancer in a VPC. The default value is INTERNET.
        public let connectionType: ConnectionType?
        /// Specifies how to handle request payload content type conversions. Supported values are CONVERT_TO_BINARY and CONVERT_TO_TEXT, with the following behaviors: If this property is not defined, the request payload will be passed through from the method request to integration request without modification, provided that the passthroughBehavior is configured to support payload pass-through.
        public let contentHandling: ContentHandlingStrategy?
        /// Specifies the credentials required for the integration, if any. For AWS integrations, three options are available. To specify an IAM Role for API Gateway to assume, use the role's Amazon Resource Name (ARN). To require that the caller's identity be passed through from the request, specify the string arn:aws:iam::\*:user/\*. To use resource-based permissions on supported Amazon Web Services services, specify null.
        public let credentials: String?
        /// Specifies the integration's HTTP method type. For the Type property, if you specify MOCK, this property is optional. For Lambda integrations, you must set the integration method to POST. For all other types, you must specify this property.
        public let httpMethod: String?
        /// Specifies the integration's responses.
        public let integrationResponses: [String: IntegrationResponse]?
        /// Specifies how the method request body of an unmapped content type will be passed through the integration request to the back end without transformation. A content type is unmapped if no mapping template is defined in the integration or the content type does not match any of the mapped content types, as specified in requestTemplates. The valid value is one of the following: WHEN_NO_MATCH: passes the method request body through the integration request to the back end without transformation when the method request content type does not match any content type associated with the mapping templates defined in the integration request. WHEN_NO_TEMPLATES: passes the method request body through the integration request to the back end without transformation when no mapping template is defined in the integration request. If a template is defined when this option is selected, the method request of an unmapped content-type will be rejected with an HTTP 415 Unsupported Media Type response. NEVER: rejects the method request with an HTTP 415 Unsupported Media Type response when either the method request content type does not match any content type associated with the mapping templates defined in the integration request or no mapping template is defined in the integration request.
        public let passthroughBehavior: String?
        /// A key-value map specifying request parameters that are passed from the method request to the back end. The key is an integration request parameter name and the associated value is a method request parameter value or static value that must be enclosed within single quotes and pre-encoded as required by the back end. The method request parameter value must match the pattern of  method.request.{location}.{name}, where location is querystring, path, or header and name must be a valid and unique method request parameter name.
        public let requestParameters: [String: String]?
        /// Represents a map of Velocity templates that are applied on the request payload based on the value of the Content-Type header sent by the client. The content type value is the key in this map, and the template (as a String) is the value.
        public let requestTemplates: [String: String]?
        /// Custom timeout between 50 and 29,000 milliseconds. The default value is 29,000 milliseconds or 29 seconds. You can increase the default value to longer than 29 seconds for Regional or private APIs only.
        public let timeoutInMillis: Int?
        /// Specifies the TLS configuration for an integration.
        public let tlsConfig: TlsConfig?
        /// Specifies an API method integration type. The valid value is one of the following: For the HTTP and HTTP proxy integrations, each integration can specify a protocol (http/https), port and path. Standard 80 and 443 ports are supported as well as custom ports above 1024. An HTTP or HTTP proxy integration with a connectionType of VPC_LINK is referred to as a private integration and uses a VpcLink to connect API Gateway to a network load balancer of a VPC.
        public let type: IntegrationType?
        /// Specifies Uniform Resource Identifier (URI) of the integration endpoint. For HTTP or HTTP_PROXY integrations, the URI must be a fully formed, encoded HTTP(S) URL
        /// 	    according to the RFC-3986 specification for standard integrations. If connectionType is VPC_LINK specify the Network Load Balancer DNS name. For AWS or AWS_PROXY integrations, the URI is of the form arn:aws:apigateway:{region}:{subdomain.service|service}:path|action/{service_api}. Here, {Region} is the API Gateway region (e.g., us-east-1); {service} is the name of the integrated Amazon Web Services service (e.g., s3); and {subdomain} is a designated subdomain supported by certain Amazon Web Services  service for fast host-name lookup. action can be used for an Amazon Web Services  service action-based API, using an Action={name}&{p1}={v1}&p2={v2}... query string. The ensuing {service_api} refers to a supported action {name} plus any required input parameters. Alternatively, path can be used for an Amazon Web Services service path-based API. The ensuing service_api refers to the path to an Amazon Web Services  service resource, including the region of the integrated Amazon Web Services  service, if applicable. For example, for integration with the S3 API of GetObject, the uri can be either arn:aws:apigateway:us-west-2:s3:action/GetObject&Bucket={bucket}&Key={key} or arn:aws:apigateway:us-west-2:s3:path/{bucket}/{key}
        public let uri: String?

        @inlinable
        public init(cacheKeyParameters: [String]? = nil, cacheNamespace: String? = nil, connectionId: String? = nil, connectionType: ConnectionType? = nil, contentHandling: ContentHandlingStrategy? = nil, credentials: String? = nil, httpMethod: String? = nil, integrationResponses: [String: IntegrationResponse]? = nil, passthroughBehavior: String? = nil, requestParameters: [String: String]? = nil, requestTemplates: [String: String]? = nil, timeoutInMillis: Int? = nil, tlsConfig: TlsConfig? = nil, type: IntegrationType? = nil, uri: String? = nil) {
            self.cacheKeyParameters = cacheKeyParameters
            self.cacheNamespace = cacheNamespace
            self.connectionId = connectionId
            self.connectionType = connectionType
            self.contentHandling = contentHandling
            self.credentials = credentials
            self.httpMethod = httpMethod
            self.integrationResponses = integrationResponses
            self.passthroughBehavior = passthroughBehavior
            self.requestParameters = requestParameters
            self.requestTemplates = requestTemplates
            self.timeoutInMillis = timeoutInMillis
            self.tlsConfig = tlsConfig
            self.type = type
            self.uri = uri
        }

        private enum CodingKeys: String, CodingKey {
            case cacheKeyParameters = "cacheKeyParameters"
            case cacheNamespace = "cacheNamespace"
            case connectionId = "connectionId"
            case connectionType = "connectionType"
            case contentHandling = "contentHandling"
            case credentials = "credentials"
            case httpMethod = "httpMethod"
            case integrationResponses = "integrationResponses"
            case passthroughBehavior = "passthroughBehavior"
            case requestParameters = "requestParameters"
            case requestTemplates = "requestTemplates"
            case timeoutInMillis = "timeoutInMillis"
            case tlsConfig = "tlsConfig"
            case type = "type"
            case uri = "uri"
        }
    }

    public struct IntegrationResponse: AWSDecodableShape {
        /// Specifies how to handle response payload content type conversions. Supported values are CONVERT_TO_BINARY and CONVERT_TO_TEXT, with the following behaviors: If this property is not defined, the response payload will be passed through from the integration response to the method response without modification.
        public let contentHandling: ContentHandlingStrategy?
        /// A key-value map specifying response parameters that are passed to the method response from the back end. The key is a method response header parameter name and the mapped value is an integration response header value, a static value enclosed within a pair of single quotes, or a JSON expression from the integration response body. The mapping key must match the pattern of method.response.header.{name}, where name is a valid and unique header name. The mapped non-static value must match the pattern of integration.response.header.{name} or integration.response.body.{JSON-expression}, where name is a valid and unique response header name and JSON-expression is a valid JSON expression without the $ prefix.
        public let responseParameters: [String: String]?
        /// Specifies the templates used to transform the integration response body. Response templates are represented as a key/value map, with a content-type as the key and a template as the value.
        public let responseTemplates: [String: String]?
        /// Specifies the regular expression (regex) pattern used to choose an integration response based on the response from the back end. For example, if the success response returns nothing and the error response returns some string, you could use the .+ regex to match error response. However, make sure that the error response does not contain any newline (\n) character in such cases. If the back end is an Lambda function, the Lambda function error header is matched. For all other HTTP and Amazon Web Services back ends, the HTTP status code is matched.
        public let selectionPattern: String?
        /// Specifies the status code that is used to map the integration response to an existing MethodResponse.
        public let statusCode: String?

        @inlinable
        public init(contentHandling: ContentHandlingStrategy? = nil, responseParameters: [String: String]? = nil, responseTemplates: [String: String]? = nil, selectionPattern: String? = nil, statusCode: String? = nil) {
            self.contentHandling = contentHandling
            self.responseParameters = responseParameters
            self.responseTemplates = responseTemplates
            self.selectionPattern = selectionPattern
            self.statusCode = statusCode
        }

        private enum CodingKeys: String, CodingKey {
            case contentHandling = "contentHandling"
            case responseParameters = "responseParameters"
            case responseTemplates = "responseTemplates"
            case selectionPattern = "selectionPattern"
            case statusCode = "statusCode"
        }
    }

    public struct LimitExceededException: AWSErrorShape {
        public let message: String?
        public let retryAfterSeconds: String?

        @inlinable
        public init(message: String? = nil, retryAfterSeconds: String? = nil) {
            self.message = message
            self.retryAfterSeconds = retryAfterSeconds
        }

        public init(from decoder: Decoder) throws {
            let response = decoder.userInfo[.awsResponse]! as! ResponseDecodingContainer
            let container = try decoder.container(keyedBy: CodingKeys.self)
            self.message = try container.decodeIfPresent(String.self, forKey: .message)
            self.retryAfterSeconds = try response.decodeHeaderIfPresent(String.self, key: "Retry-After")
        }

        private enum CodingKeys: String, CodingKey {
            case message = "message"
        }
    }

    public struct Method: AWSDecodableShape {
        /// A boolean flag specifying whether a valid ApiKey is required to invoke this method.
        public let apiKeyRequired: Bool?
        /// A list of authorization scopes configured on the method. The scopes are used with a COGNITO_USER_POOLS authorizer to authorize the method invocation. The authorization works by matching the method scopes against the scopes parsed from the access token in the incoming request. The method invocation is authorized if any method scopes matches a claimed scope in the access token. Otherwise, the invocation is not authorized. When the method scope is configured, the client must provide an access token instead of an identity token for authorization purposes.
        public let authorizationScopes: [String]?
        /// The method's authorization type. Valid values are NONE for open access, AWS_IAM for using AWS IAM permissions, CUSTOM for using a custom authorizer, or COGNITO_USER_POOLS for using a Cognito user pool.
        public let authorizationType: String?
        /// The identifier of an Authorizer to use on this method. The authorizationType must be CUSTOM.
        public let authorizerId: String?
        /// The method's HTTP verb.
        public let httpMethod: String?
        /// Gets the method's integration responsible for passing the client-submitted request to the back end and performing necessary transformations to make the request compliant with the back end.
        public let methodIntegration: Integration?
        /// Gets a method response associated with a given HTTP status code.
        public let methodResponses: [String: MethodResponse]?
        /// A human-friendly operation identifier for the method. For example, you can assign the operationName of ListPets for the GET /pets method in the PetStore example.
        public let operationName: String?
        /// A key-value map specifying data schemas, represented by Model resources, (as the mapped value) of the request payloads of given content types (as the mapping key).
        public let requestModels: [String: String]?
        /// A key-value map defining required or optional method request parameters that can be accepted by API Gateway. A key is a method request parameter name matching the pattern of  method.request.{location}.{name}, where location is querystring, path, or header and name is a valid and unique parameter name. The value associated with the key is a Boolean flag indicating whether the parameter is required (true) or optional (false).  The method request parameter names defined here are available in Integration to be mapped to integration request parameters or templates.
        public let requestParameters: [String: Bool]?
        /// The identifier of a RequestValidator for request validation.
        public let requestValidatorId: String?

        @inlinable
        public init(apiKeyRequired: Bool? = nil, authorizationScopes: [String]? = nil, authorizationType: String? = nil, authorizerId: String? = nil, httpMethod: String? = nil, methodIntegration: Integration? = nil, methodResponses: [String: MethodResponse]? = nil, operationName: String? = nil, requestModels: [String: String]? = nil, requestParameters: [String: Bool]? = nil, requestValidatorId: String? = nil) {
            self.apiKeyRequired = apiKeyRequired
            self.authorizationScopes = authorizationScopes
            self.authorizationType = authorizationType
            self.authorizerId = authorizerId
            self.httpMethod = httpMethod
            self.methodIntegration = methodIntegration
            self.methodResponses = methodResponses
            self.operationName = operationName
            self.requestModels = requestModels
            self.requestParameters = requestParameters
            self.requestValidatorId = requestValidatorId
        }

        private enum CodingKeys: String, CodingKey {
            case apiKeyRequired = "apiKeyRequired"
            case authorizationScopes = "authorizationScopes"
            case authorizationType = "authorizationType"
            case authorizerId = "authorizerId"
            case httpMethod = "httpMethod"
            case methodIntegration = "methodIntegration"
            case methodResponses = "methodResponses"
            case operationName = "operationName"
            case requestModels = "requestModels"
            case requestParameters = "requestParameters"
            case requestValidatorId = "requestValidatorId"
        }
    }

    public struct MethodResponse: AWSDecodableShape {
        /// Specifies the Model resources used for the response's content-type. Response models are represented as a key/value map, with a content-type as the key and a Model name as the value.
        public let responseModels: [String: String]?
        /// A key-value map specifying required or optional response parameters that API Gateway can send back to the caller. A key defines a method response header and the value specifies whether the associated method response header is required or not. The expression of the key must match the pattern method.response.header.{name}, where name is a valid and unique header name. API Gateway passes certain integration response data to the method response headers specified here according to the mapping you prescribe in the API's IntegrationResponse. The integration response data that can be mapped include an integration response header expressed in integration.response.header.{name}, a static value enclosed within a pair of single quotes (e.g., 'application/json'), or a JSON expression from the back-end response payload in the form of integration.response.body.{JSON-expression}, where JSON-expression is a valid JSON expression without the $ prefix.)
        public let responseParameters: [String: Bool]?
        /// The method response's status code.
        public let statusCode: String?

        @inlinable
        public init(responseModels: [String: String]? = nil, responseParameters: [String: Bool]? = nil, statusCode: String? = nil) {
            self.responseModels = responseModels
            self.responseParameters = responseParameters
            self.statusCode = statusCode
        }

        private enum CodingKeys: String, CodingKey {
            case responseModels = "responseModels"
            case responseParameters = "responseParameters"
            case statusCode = "statusCode"
        }
    }

    public struct MethodSetting: AWSDecodableShape {
        /// Specifies whether the cached responses are encrypted.
        public let cacheDataEncrypted: Bool?
        /// Specifies the time to live (TTL), in seconds, for cached responses. The higher the TTL, the longer the response will be cached.
        public let cacheTtlInSeconds: Int?
        /// Specifies whether responses should be cached and returned for requests. A cache cluster must be enabled on the stage for responses to be cached.
        public let cachingEnabled: Bool?
        /// Specifies whether data trace logging is enabled for this method, which affects the log entries pushed to Amazon CloudWatch Logs. This can be useful to troubleshoot APIs, but can result in logging sensitive data. We recommend that you don't enable this option for production APIs.
        public let dataTraceEnabled: Bool?
        /// Specifies the logging level for this method, which affects the log entries pushed to Amazon CloudWatch Logs. Valid values are OFF, ERROR, and INFO. Choose ERROR to write only error-level entries to CloudWatch Logs, or choose INFO to include all ERROR events as well as extra informational events.
        public let loggingLevel: String?
        /// Specifies whether Amazon CloudWatch metrics are enabled for this method.
        public let metricsEnabled: Bool?
        /// Specifies whether authorization is required for a cache invalidation request.
        public let requireAuthorizationForCacheControl: Bool?
        /// Specifies the throttling burst limit.
        public let throttlingBurstLimit: Int?
        /// Specifies the throttling rate limit.
        public let throttlingRateLimit: Double?
        /// Specifies how to handle unauthorized requests for cache invalidation.
        public let unauthorizedCacheControlHeaderStrategy: UnauthorizedCacheControlHeaderStrategy?

        @inlinable
        public init(cacheDataEncrypted: Bool? = nil, cacheTtlInSeconds: Int? = nil, cachingEnabled: Bool? = nil, dataTraceEnabled: Bool? = nil, loggingLevel: String? = nil, metricsEnabled: Bool? = nil, requireAuthorizationForCacheControl: Bool? = nil, throttlingBurstLimit: Int? = nil, throttlingRateLimit: Double? = nil, unauthorizedCacheControlHeaderStrategy: UnauthorizedCacheControlHeaderStrategy? = nil) {
            self.cacheDataEncrypted = cacheDataEncrypted
            self.cacheTtlInSeconds = cacheTtlInSeconds
            self.cachingEnabled = cachingEnabled
            self.dataTraceEnabled = dataTraceEnabled
            self.loggingLevel = loggingLevel
            self.metricsEnabled = metricsEnabled
            self.requireAuthorizationForCacheControl = requireAuthorizationForCacheControl
            self.throttlingBurstLimit = throttlingBurstLimit
            self.throttlingRateLimit = throttlingRateLimit
            self.unauthorizedCacheControlHeaderStrategy = unauthorizedCacheControlHeaderStrategy
        }

        private enum CodingKeys: String, CodingKey {
            case cacheDataEncrypted = "cacheDataEncrypted"
            case cacheTtlInSeconds = "cacheTtlInSeconds"
            case cachingEnabled = "cachingEnabled"
            case dataTraceEnabled = "dataTraceEnabled"
            case loggingLevel = "loggingLevel"
            case metricsEnabled = "metricsEnabled"
            case requireAuthorizationForCacheControl = "requireAuthorizationForCacheControl"
            case throttlingBurstLimit = "throttlingBurstLimit"
            case throttlingRateLimit = "throttlingRateLimit"
            case unauthorizedCacheControlHeaderStrategy = "unauthorizedCacheControlHeaderStrategy"
        }
    }

    public struct MethodSnapshot: AWSDecodableShape {
        /// Specifies whether the method requires a valid ApiKey.
        public let apiKeyRequired: Bool?
        /// The method's authorization type. Valid values are NONE for open access, AWS_IAM for using AWS IAM permissions, CUSTOM for using a custom authorizer, or COGNITO_USER_POOLS for using a Cognito user pool.
        public let authorizationType: String?

        @inlinable
        public init(apiKeyRequired: Bool? = nil, authorizationType: String? = nil) {
            self.apiKeyRequired = apiKeyRequired
            self.authorizationType = authorizationType
        }

        private enum CodingKeys: String, CodingKey {
            case apiKeyRequired = "apiKeyRequired"
            case authorizationType = "authorizationType"
        }
    }

    public struct Model: AWSDecodableShape {
        /// The content-type for the model.
        public let contentType: String?
        /// The description of the model.
        public let description: String?
        /// The identifier for the model resource.
        public let id: String?
        /// The name of the model. Must be an alphanumeric string.
        public let name: String?
        /// The schema for the model. For application/json models, this should be JSON schema draft 4 model. Do not include "\*/" characters in the description of any properties because such "\*/" characters may be interpreted as the closing marker for comments in some languages, such as Java or JavaScript, causing the installation of your API's SDK generated by API Gateway to fail.
        public let schema: String?

        @inlinable
        public init(contentType: String? = nil, description: String? = nil, id: String? = nil, name: String? = nil, schema: String? = nil) {
            self.contentType = contentType
            self.description = description
            self.id = id
            self.name = name
            self.schema = schema
        }

        private enum CodingKeys: String, CodingKey {
            case contentType = "contentType"
            case description = "description"
            case id = "id"
            case name = "name"
            case schema = "schema"
        }
    }

    public struct Models: AWSDecodableShape {
        /// The current page of elements from this collection.
        public let items: [Model]?
        /// The current pagination position in the paged result set.
        public let position: String?

        @inlinable
        public init(items: [Model]? = nil, position: String? = nil) {
            self.items = items
            self.position = position
        }

        private enum CodingKeys: String, CodingKey {
            case items = "item"
            case position = "position"
        }
    }

    public struct MutualTlsAuthentication: AWSDecodableShape {
        /// An Amazon S3 URL that specifies the truststore for mutual TLS authentication, for example s3://bucket-name/key-name. The truststore can contain certificates from public or private certificate authorities. To update the truststore, upload a new version to S3, and then update your custom domain name to use the new version. To update the truststore, you must have permissions to access the S3 object.
        public let truststoreUri: String?
        /// The version of the S3 object that contains your truststore. To specify a version, you must have versioning enabled for the S3 bucket.
        public let truststoreVersion: String?
        /// A list of warnings that API Gateway returns while processing your truststore. Invalid certificates produce warnings. Mutual TLS is still enabled, but some clients might not be able to access your API. To resolve warnings, upload a new truststore to S3, and then update you domain name to use the new version.
        public let truststoreWarnings: [String]?

        @inlinable
        public init(truststoreUri: String? = nil, truststoreVersion: String? = nil, truststoreWarnings: [String]? = nil) {
            self.truststoreUri = truststoreUri
            self.truststoreVersion = truststoreVersion
            self.truststoreWarnings = truststoreWarnings
        }

        private enum CodingKeys: String, CodingKey {
            case truststoreUri = "truststoreUri"
            case truststoreVersion = "truststoreVersion"
            case truststoreWarnings = "truststoreWarnings"
        }
    }

    public struct MutualTlsAuthenticationInput: AWSEncodableShape {
        /// An Amazon S3 URL that specifies the truststore for mutual TLS authentication, for example s3://bucket-name/key-name. The truststore can contain certificates from public or private certificate authorities. To update the truststore, upload a new version to S3, and then update your custom domain name to use the new version. To update the truststore, you must have permissions to access the S3 object.
        public let truststoreUri: String?
        /// The version of the S3 object that contains your truststore. To specify a version, you must have versioning enabled for the S3 bucket
        public let truststoreVersion: String?

        @inlinable
        public init(truststoreUri: String? = nil, truststoreVersion: String? = nil) {
            self.truststoreUri = truststoreUri
            self.truststoreVersion = truststoreVersion
        }

        private enum CodingKeys: String, CodingKey {
            case truststoreUri = "truststoreUri"
            case truststoreVersion = "truststoreVersion"
        }
    }

    public struct PatchOperation: AWSEncodableShape {
        /// The copy update operation's source as identified by a JSON-Pointer value referencing the location within the targeted resource to copy the value from. For example, to promote a canary deployment, you copy the canary deployment ID to the affiliated deployment ID by calling a PATCH request on a Stage resource with "op":"copy", "from":"/canarySettings/deploymentId" and "path":"/deploymentId".
        public let from: String?
        /// An update operation to be performed with this PATCH request. The valid value can be add, remove, replace or copy. Not all valid operations are supported for a given resource. Support of the operations depends on specific operational contexts. Attempts to apply an unsupported operation on a resource will return an error message..
        public let op: Op?
        /// The op operation's target, as identified by a JSON Pointer value that references a location within the targeted resource. For example, if the target resource has an updateable property of {"name":"value"}, the path for this property is /name. If the name property value is a JSON object (e.g., {"name": {"child/name": "child-value"}}), the path for the child/name property will be /name/child~1name. Any slash ("/") character appearing in path names must be escaped with "~1", as shown in the example above. Each op operation can have only one path associated with it.
        public let path: String?
        /// The new target value of the update operation. It is applicable for the add or replace operation. When using AWS CLI to update a property of a JSON value, enclose the JSON object with a pair of single quotes in a Linux shell, e.g., '{"a": ...}'.
        public let value: String?

        @inlinable
        public init(from: String? = nil, op: Op? = nil, path: String? = nil, value: String? = nil) {
            self.from = from
            self.op = op
            self.path = path
            self.value = value
        }

        private enum CodingKeys: String, CodingKey {
            case from = "from"
            case op = "op"
            case path = "path"
            case value = "value"
        }
    }

    public struct PutGatewayResponseRequest: AWSEncodableShape {
        /// Response parameters (paths, query strings and headers) of the GatewayResponse as a string-to-string map of key-value  pairs.
        public let responseParameters: [String: String]?
        /// Response templates of the GatewayResponse as a string-to-string map of key-value pairs.
        public let responseTemplates: [String: String]?
        /// The response type of the associated GatewayResponse
        public let responseType: GatewayResponseType
        /// The string identifier of the associated RestApi.
        public let restApiId: String
        /// The HTTP status code of the GatewayResponse.
        public let statusCode: String?

        @inlinable
        public init(responseParameters: [String: String]? = nil, responseTemplates: [String: String]? = nil, responseType: GatewayResponseType, restApiId: String, statusCode: String? = nil) {
            self.responseParameters = responseParameters
            self.responseTemplates = responseTemplates
            self.responseType = responseType
            self.restApiId = restApiId
            self.statusCode = statusCode
        }

        public func encode(to encoder: Encoder) throws {
            let request = encoder.userInfo[.awsRequest]! as! RequestEncodingContainer
            var container = encoder.container(keyedBy: CodingKeys.self)
            try container.encodeIfPresent(self.responseParameters, forKey: .responseParameters)
            try container.encodeIfPresent(self.responseTemplates, forKey: .responseTemplates)
            request.encodePath(self.responseType, key: "responseType")
            request.encodePath(self.restApiId, key: "restApiId")
            try container.encodeIfPresent(self.statusCode, forKey: .statusCode)
        }

        public func validate(name: String) throws {
            try self.validate(self.statusCode, name: "statusCode", parent: name, pattern: "^[1-5]\\d\\d$")
        }

        private enum CodingKeys: String, CodingKey {
            case responseParameters = "responseParameters"
            case responseTemplates = "responseTemplates"
            case statusCode = "statusCode"
        }
    }

    public struct PutIntegrationRequest: AWSEncodableShape {
        /// A list of request parameters whose values API Gateway caches. To be valid values for cacheKeyParameters, these parameters must also be specified for Method requestParameters.
        public let cacheKeyParameters: [String]?
        /// Specifies a group of related cached parameters. By default, API Gateway uses the resource ID as the cacheNamespace. You can specify the same cacheNamespace across resources to return the same cached data for requests to different resources.
        public let cacheNamespace: String?
        /// The ID of the VpcLink used for the integration. Specify this value only if you specify VPC_LINK as the connection type.
        public let connectionId: String?
        /// The type of the network connection to the integration endpoint. The valid value is INTERNET for connections through the public routable internet or VPC_LINK for private connections between API Gateway and a network load balancer in a VPC. The default value is INTERNET.
        public let connectionType: ConnectionType?
        /// Specifies how to handle request payload content type conversions. Supported values are CONVERT_TO_BINARY and CONVERT_TO_TEXT, with the following behaviors: If this property is not defined, the request payload will be passed through from the method request to integration request without modification, provided that the passthroughBehavior is configured to support payload pass-through.
        public let contentHandling: ContentHandlingStrategy?
        /// Specifies whether credentials are required for a put integration.
        public let credentials: String?
        /// Specifies the HTTP method for the integration.
        public let httpMethod: String
        /// The HTTP method for the integration.
        public let integrationHttpMethod: String?
        /// Specifies the pass-through behavior for incoming requests based on the Content-Type header in the request, and the available mapping templates specified as the requestTemplates property on the Integration resource. There are three valid values:  WHEN_NO_MATCH, WHEN_NO_TEMPLATES, and NEVER.
        public let passthroughBehavior: String?
        /// A key-value map specifying request parameters that are passed from the method request to the back end. The key is an integration request parameter name and the associated value is a method request parameter value or static value that must be enclosed within single quotes and pre-encoded as required by the back end. The method request parameter value must match the pattern of  method.request.{location}.{name}, where location is querystring, path, or header and name must be a valid and unique method request parameter name.
        public let requestParameters: [String: String]?
        /// Represents a map of Velocity templates that are applied on the request payload based on the value of the Content-Type header sent by the client. The content type value is the key in this map, and the template (as a String) is the value.
        public let requestTemplates: [String: String]?
        /// Specifies a put integration request's resource ID.
        public let resourceId: String
        /// The string identifier of the associated RestApi.
        public let restApiId: String
        /// Custom timeout between 50 and 29,000 milliseconds. The default value is 29,000 milliseconds or 29 seconds.  You can increase the default value to longer than 29 seconds for Regional or private APIs only.
        public let timeoutInMillis: Int?
        public let tlsConfig: TlsConfig?
        /// Specifies a put integration input's type.
        public let type: IntegrationType
        /// Specifies Uniform Resource Identifier (URI) of the integration endpoint. For HTTP or HTTP_PROXY integrations, the URI must be a fully formed, encoded HTTP(S) URL according to the RFC-3986 specification, for either standard integration, where connectionType is not VPC_LINK, or private integration, where connectionType is VPC_LINK. For a private HTTP integration, the URI is not used for routing. For AWS or AWS_PROXY integrations, the URI is of the form arn:aws:apigateway:{region}:{subdomain.service|service}:path|action/{service_api}. Here, {Region} is the API Gateway region (e.g., us-east-1); {service} is the name of the integrated Amazon Web Services service (e.g., s3); and {subdomain} is a designated subdomain supported by certain Amazon Web Services service for fast host-name lookup. action can be used for an Amazon Web Services service action-based API, using an Action={name}&{p1}={v1}&p2={v2}... query string. The ensuing {service_api} refers to a supported action {name} plus any required input parameters. Alternatively, path can be used for an Amazon Web Services service path-based API. The ensuing service_api refers to the path to an Amazon Web Services service resource, including the region of the integrated Amazon Web Services service, if applicable. For example, for integration with the S3 API of GetObject, the uri can be either arn:aws:apigateway:us-west-2:s3:action/GetObject&Bucket={bucket}&Key={key} or arn:aws:apigateway:us-west-2:s3:path/{bucket}/{key}.
        public let uri: String?

        @inlinable
        public init(cacheKeyParameters: [String]? = nil, cacheNamespace: String? = nil, connectionId: String? = nil, connectionType: ConnectionType? = nil, contentHandling: ContentHandlingStrategy? = nil, credentials: String? = nil, httpMethod: String, integrationHttpMethod: String? = nil, passthroughBehavior: String? = nil, requestParameters: [String: String]? = nil, requestTemplates: [String: String]? = nil, resourceId: String, restApiId: String, timeoutInMillis: Int? = nil, tlsConfig: TlsConfig? = nil, type: IntegrationType, uri: String? = nil) {
            self.cacheKeyParameters = cacheKeyParameters
            self.cacheNamespace = cacheNamespace
            self.connectionId = connectionId
            self.connectionType = connectionType
            self.contentHandling = contentHandling
            self.credentials = credentials
            self.httpMethod = httpMethod
            self.integrationHttpMethod = integrationHttpMethod
            self.passthroughBehavior = passthroughBehavior
            self.requestParameters = requestParameters
            self.requestTemplates = requestTemplates
            self.resourceId = resourceId
            self.restApiId = restApiId
            self.timeoutInMillis = timeoutInMillis
            self.tlsConfig = tlsConfig
            self.type = type
            self.uri = uri
        }

        public func encode(to encoder: Encoder) throws {
            let request = encoder.userInfo[.awsRequest]! as! RequestEncodingContainer
            var container = encoder.container(keyedBy: CodingKeys.self)
            try container.encodeIfPresent(self.cacheKeyParameters, forKey: .cacheKeyParameters)
            try container.encodeIfPresent(self.cacheNamespace, forKey: .cacheNamespace)
            try container.encodeIfPresent(self.connectionId, forKey: .connectionId)
            try container.encodeIfPresent(self.connectionType, forKey: .connectionType)
            try container.encodeIfPresent(self.contentHandling, forKey: .contentHandling)
            try container.encodeIfPresent(self.credentials, forKey: .credentials)
            request.encodePath(self.httpMethod, key: "requestHttpMethod")
            try container.encodeIfPresent(self.integrationHttpMethod, forKey: .integrationHttpMethod)
            try container.encodeIfPresent(self.passthroughBehavior, forKey: .passthroughBehavior)
            try container.encodeIfPresent(self.requestParameters, forKey: .requestParameters)
            try container.encodeIfPresent(self.requestTemplates, forKey: .requestTemplates)
            request.encodePath(self.resourceId, key: "resourceId")
            request.encodePath(self.restApiId, key: "restApiId")
            try container.encodeIfPresent(self.timeoutInMillis, forKey: .timeoutInMillis)
            try container.encodeIfPresent(self.tlsConfig, forKey: .tlsConfig)
            try container.encode(self.type, forKey: .type)
            try container.encodeIfPresent(self.uri, forKey: .uri)
        }

        private enum CodingKeys: String, CodingKey {
            case cacheKeyParameters = "cacheKeyParameters"
            case cacheNamespace = "cacheNamespace"
            case connectionId = "connectionId"
            case connectionType = "connectionType"
            case contentHandling = "contentHandling"
            case credentials = "credentials"
            case integrationHttpMethod = "httpMethod"
            case passthroughBehavior = "passthroughBehavior"
            case requestParameters = "requestParameters"
            case requestTemplates = "requestTemplates"
            case timeoutInMillis = "timeoutInMillis"
            case tlsConfig = "tlsConfig"
            case type = "type"
            case uri = "uri"
        }
    }

    public struct PutIntegrationResponseRequest: AWSEncodableShape {
        /// Specifies how to handle response payload content type conversions. Supported values are CONVERT_TO_BINARY and CONVERT_TO_TEXT, with the following behaviors: If this property is not defined, the response payload will be passed through from the integration response to the method response without modification.
        public let contentHandling: ContentHandlingStrategy?
        /// Specifies a put integration response request's HTTP method.
        public let httpMethod: String
        /// Specifies a put integration response request's resource identifier.
        public let resourceId: String
        /// A key-value map specifying response parameters that are passed to the method response from the back end. The key is a method response header parameter name and the mapped value is an integration response header value, a static value enclosed within a pair of single quotes, or a JSON expression from the integration response body. The mapping key must match the pattern of method.response.header.{name}, where name is a valid and unique header name. The mapped non-static value must match the pattern of integration.response.header.{name} or integration.response.body.{JSON-expression}, where name must be a valid and unique response header name and JSON-expression a valid JSON expression without the $ prefix.
        public let responseParameters: [String: String]?
        /// Specifies a put integration response's templates.
        public let responseTemplates: [String: String]?
        /// The string identifier of the associated RestApi.
        public let restApiId: String
        /// Specifies the selection pattern of a put integration response.
        public let selectionPattern: String?
        /// Specifies the status code that is used to map the integration response to an existing MethodResponse.
        public let statusCode: String

        @inlinable
        public init(contentHandling: ContentHandlingStrategy? = nil, httpMethod: String, resourceId: String, responseParameters: [String: String]? = nil, responseTemplates: [String: String]? = nil, restApiId: String, selectionPattern: String? = nil, statusCode: String) {
            self.contentHandling = contentHandling
            self.httpMethod = httpMethod
            self.resourceId = resourceId
            self.responseParameters = responseParameters
            self.responseTemplates = responseTemplates
            self.restApiId = restApiId
            self.selectionPattern = selectionPattern
            self.statusCode = statusCode
        }

        public func encode(to encoder: Encoder) throws {
            let request = encoder.userInfo[.awsRequest]! as! RequestEncodingContainer
            var container = encoder.container(keyedBy: CodingKeys.self)
            try container.encodeIfPresent(self.contentHandling, forKey: .contentHandling)
            request.encodePath(self.httpMethod, key: "httpMethod")
            request.encodePath(self.resourceId, key: "resourceId")
            try container.encodeIfPresent(self.responseParameters, forKey: .responseParameters)
            try container.encodeIfPresent(self.responseTemplates, forKey: .responseTemplates)
            request.encodePath(self.restApiId, key: "restApiId")
            try container.encodeIfPresent(self.selectionPattern, forKey: .selectionPattern)
            request.encodePath(self.statusCode, key: "statusCode")
        }

        public func validate(name: String) throws {
            try self.validate(self.statusCode, name: "statusCode", parent: name, pattern: "^[1-5]\\d\\d$")
        }

        private enum CodingKeys: String, CodingKey {
            case contentHandling = "contentHandling"
            case responseParameters = "responseParameters"
            case responseTemplates = "responseTemplates"
            case selectionPattern = "selectionPattern"
        }
    }

    public struct PutMethodRequest: AWSEncodableShape {
        /// Specifies whether the method required a valid ApiKey.
        public let apiKeyRequired: Bool?
        /// A list of authorization scopes configured on the method. The scopes are used with a COGNITO_USER_POOLS authorizer to authorize the method invocation. The authorization works by matching the method scopes against the scopes parsed from the access token in the incoming request. The method invocation is authorized if any method scopes matches a claimed scope in the access token. Otherwise, the invocation is not authorized. When the method scope is configured, the client must provide an access token instead of an identity token for authorization purposes.
        public let authorizationScopes: [String]?
        /// The method's authorization type. Valid values are NONE for open access, AWS_IAM for using AWS IAM permissions, CUSTOM for using a custom authorizer, or COGNITO_USER_POOLS for using a Cognito user pool.
        public let authorizationType: String
        /// Specifies the identifier of an Authorizer to use on this Method, if the type is CUSTOM or COGNITO_USER_POOLS. The authorizer identifier is generated by API Gateway when you created the authorizer.
        public let authorizerId: String?
        /// Specifies the method request's HTTP method type.
        public let httpMethod: String
        /// A human-friendly operation identifier for the method. For example, you can assign the operationName of ListPets for the GET /pets method in the PetStore example.
        public let operationName: String?
        /// Specifies the Model resources used for the request's content type. Request models are represented as a key/value map, with a content type as the key and a Model name as the value.
        public let requestModels: [String: String]?
        /// A key-value map defining required or optional method request parameters that can be accepted by API Gateway. A key defines a method request parameter name matching the pattern of  method.request.{location}.{name}, where location is querystring, path, or header and name is a valid and unique parameter name. The value associated with the key is a Boolean flag indicating whether the parameter is required (true) or optional (false).  The method request parameter names defined here are available in Integration to be mapped to integration request parameters or body-mapping templates.
        public let requestParameters: [String: Bool]?
        /// The identifier of a RequestValidator for validating the method request.
        public let requestValidatorId: String?
        /// The Resource identifier for the new Method resource.
        public let resourceId: String
        /// The string identifier of the associated RestApi.
        public let restApiId: String

        @inlinable
        public init(apiKeyRequired: Bool? = nil, authorizationScopes: [String]? = nil, authorizationType: String, authorizerId: String? = nil, httpMethod: String, operationName: String? = nil, requestModels: [String: String]? = nil, requestParameters: [String: Bool]? = nil, requestValidatorId: String? = nil, resourceId: String, restApiId: String) {
            self.apiKeyRequired = apiKeyRequired
            self.authorizationScopes = authorizationScopes
            self.authorizationType = authorizationType
            self.authorizerId = authorizerId
            self.httpMethod = httpMethod
            self.operationName = operationName
            self.requestModels = requestModels
            self.requestParameters = requestParameters
            self.requestValidatorId = requestValidatorId
            self.resourceId = resourceId
            self.restApiId = restApiId
        }

        public func encode(to encoder: Encoder) throws {
            let request = encoder.userInfo[.awsRequest]! as! RequestEncodingContainer
            var container = encoder.container(keyedBy: CodingKeys.self)
            try container.encodeIfPresent(self.apiKeyRequired, forKey: .apiKeyRequired)
            try container.encodeIfPresent(self.authorizationScopes, forKey: .authorizationScopes)
            try container.encode(self.authorizationType, forKey: .authorizationType)
            try container.encodeIfPresent(self.authorizerId, forKey: .authorizerId)
            request.encodePath(self.httpMethod, key: "httpMethod")
            try container.encodeIfPresent(self.operationName, forKey: .operationName)
            try container.encodeIfPresent(self.requestModels, forKey: .requestModels)
            try container.encodeIfPresent(self.requestParameters, forKey: .requestParameters)
            try container.encodeIfPresent(self.requestValidatorId, forKey: .requestValidatorId)
            request.encodePath(self.resourceId, key: "resourceId")
            request.encodePath(self.restApiId, key: "restApiId")
        }

        private enum CodingKeys: String, CodingKey {
            case apiKeyRequired = "apiKeyRequired"
            case authorizationScopes = "authorizationScopes"
            case authorizationType = "authorizationType"
            case authorizerId = "authorizerId"
            case operationName = "operationName"
            case requestModels = "requestModels"
            case requestParameters = "requestParameters"
            case requestValidatorId = "requestValidatorId"
        }
    }

    public struct PutMethodResponseRequest: AWSEncodableShape {
        /// The HTTP verb of the Method resource.
        public let httpMethod: String
        /// The Resource identifier for the Method resource.
        public let resourceId: String
        /// Specifies the Model resources used for the response's content type. Response models are represented as a key/value map, with a content type as the key and a Model name as the value.
        public let responseModels: [String: String]?
        /// A key-value map specifying required or optional response parameters that API Gateway can send back to the caller. A key defines a method response header name and the associated value is a Boolean flag indicating whether the method response parameter is required or not. The method response header names must match the pattern of method.response.header.{name}, where name is a valid and unique header name. The response parameter names defined here are available in the integration response to be mapped from an integration response header expressed in integration.response.header.{name}, a static value enclosed within a pair of single quotes (e.g., 'application/json'), or a JSON expression from the back-end response payload in the form of integration.response.body.{JSON-expression}, where JSON-expression is a valid JSON expression without the $ prefix.)
        public let responseParameters: [String: Bool]?
        /// The string identifier of the associated RestApi.
        public let restApiId: String
        /// The method response's status code.
        public let statusCode: String

        @inlinable
        public init(httpMethod: String, resourceId: String, responseModels: [String: String]? = nil, responseParameters: [String: Bool]? = nil, restApiId: String, statusCode: String) {
            self.httpMethod = httpMethod
            self.resourceId = resourceId
            self.responseModels = responseModels
            self.responseParameters = responseParameters
            self.restApiId = restApiId
            self.statusCode = statusCode
        }

        public func encode(to encoder: Encoder) throws {
            let request = encoder.userInfo[.awsRequest]! as! RequestEncodingContainer
            var container = encoder.container(keyedBy: CodingKeys.self)
            request.encodePath(self.httpMethod, key: "httpMethod")
            request.encodePath(self.resourceId, key: "resourceId")
            try container.encodeIfPresent(self.responseModels, forKey: .responseModels)
            try container.encodeIfPresent(self.responseParameters, forKey: .responseParameters)
            request.encodePath(self.restApiId, key: "restApiId")
            request.encodePath(self.statusCode, key: "statusCode")
        }

        public func validate(name: String) throws {
            try self.validate(self.statusCode, name: "statusCode", parent: name, pattern: "^[1-5]\\d\\d$")
        }

        private enum CodingKeys: String, CodingKey {
            case responseModels = "responseModels"
            case responseParameters = "responseParameters"
        }
    }

    public struct PutRestApiRequest: AWSEncodableShape {
        /// The PUT request body containing external API definitions. Currently, only OpenAPI definition JSON/YAML files are supported. The maximum size of the API definition file is 6MB.
        public let body: AWSHTTPBody
        /// A query parameter to indicate whether to rollback the API update (true) or not (false) when a warning is encountered. The default value is false.
        public let failOnWarnings: Bool?
        /// The mode query parameter to specify the update mode. Valid values are "merge" and "overwrite". By default, the update mode is "merge".
        public let mode: PutMode?
        /// Custom header parameters as part of the request. For example, to exclude DocumentationParts from an imported API, set ignore=documentation as a parameters value, as in the AWS CLI command of aws apigateway import-rest-api --parameters ignore=documentation --body 'file:///path/to/imported-api-body.json'.
        public let parameters: [String: String]?
        /// The string identifier of the associated RestApi.
        public let restApiId: String

        @inlinable
        public init(body: AWSHTTPBody, failOnWarnings: Bool? = nil, mode: PutMode? = nil, parameters: [String: String]? = nil, restApiId: String) {
            self.body = body
            self.failOnWarnings = failOnWarnings
            self.mode = mode
            self.parameters = parameters
            self.restApiId = restApiId
        }

        public func encode(to encoder: Encoder) throws {
            let request = encoder.userInfo[.awsRequest]! as! RequestEncodingContainer
            var container = encoder.singleValueContainer()
            try container.encode(self.body)
            request.encodeQuery(self.failOnWarnings, key: "failonwarnings")
            request.encodeQuery(self.mode, key: "mode")
            request.encodeQuery(self.parameters)
            request.encodePath(self.restApiId, key: "restApiId")
        }

        private enum CodingKeys: CodingKey {}
    }

    public struct QuotaSettings: AWSEncodableShape & AWSDecodableShape {
        /// The target maximum number of requests that can be made in a given time period.
        public let limit: Int?
        /// The number of requests subtracted from the given limit in the initial time period.
        public let offset: Int?
        /// The time period in which the limit applies. Valid values are "DAY", "WEEK" or "MONTH".
        public let period: QuotaPeriodType?

        @inlinable
        public init(limit: Int? = nil, offset: Int? = nil, period: QuotaPeriodType? = nil) {
            self.limit = limit
            self.offset = offset
            self.period = period
        }

        private enum CodingKeys: String, CodingKey {
            case limit = "limit"
            case offset = "offset"
            case period = "period"
        }
    }

    public struct RejectDomainNameAccessAssociationRequest: AWSEncodableShape {
        /// The ARN of the domain name access association resource.
        public let domainNameAccessAssociationArn: String
        /// The ARN of the domain name.
        public let domainNameArn: String

        @inlinable
        public init(domainNameAccessAssociationArn: String, domainNameArn: String) {
            self.domainNameAccessAssociationArn = domainNameAccessAssociationArn
            self.domainNameArn = domainNameArn
        }

        public func encode(to encoder: Encoder) throws {
            let request = encoder.userInfo[.awsRequest]! as! RequestEncodingContainer
            _ = encoder.container(keyedBy: CodingKeys.self)
            request.encodeQuery(self.domainNameAccessAssociationArn, key: "domainNameAccessAssociationArn")
            request.encodeQuery(self.domainNameArn, key: "domainNameArn")
        }

        private enum CodingKeys: CodingKey {}
    }

    public struct RequestValidator: AWSDecodableShape {
        /// The identifier of this RequestValidator.
        public let id: String?
        /// The name of this RequestValidator
        public let name: String?
        /// A Boolean flag to indicate whether to validate a request body according to the configured Model schema.
        public let validateRequestBody: Bool?
        /// A Boolean flag to indicate whether to validate request parameters (true) or not (false).
        public let validateRequestParameters: Bool?

        @inlinable
        public init(id: String? = nil, name: String? = nil, validateRequestBody: Bool? = nil, validateRequestParameters: Bool? = nil) {
            self.id = id
            self.name = name
            self.validateRequestBody = validateRequestBody
            self.validateRequestParameters = validateRequestParameters
        }

        private enum CodingKeys: String, CodingKey {
            case id = "id"
            case name = "name"
            case validateRequestBody = "validateRequestBody"
            case validateRequestParameters = "validateRequestParameters"
        }
    }

    public struct RequestValidators: AWSDecodableShape {
        /// The current page of elements from this collection.
        public let items: [RequestValidator]?
        /// The current pagination position in the paged result set.
        public let position: String?

        @inlinable
        public init(items: [RequestValidator]? = nil, position: String? = nil) {
            self.items = items
            self.position = position
        }

        private enum CodingKeys: String, CodingKey {
            case items = "item"
            case position = "position"
        }
    }

    public struct Resource: AWSDecodableShape {
        /// The resource's identifier.
        public let id: String?
        /// The parent resource's identifier.
        public let parentId: String?
        /// The full path for this resource.
        public let path: String?
        /// The last path segment for this resource.
        public let pathPart: String?
        /// Gets an API resource's method of a given HTTP verb.
        public let resourceMethods: [String: Method]?

        @inlinable
        public init(id: String? = nil, parentId: String? = nil, path: String? = nil, pathPart: String? = nil, resourceMethods: [String: Method]? = nil) {
            self.id = id
            self.parentId = parentId
            self.path = path
            self.pathPart = pathPart
            self.resourceMethods = resourceMethods
        }

        private enum CodingKeys: String, CodingKey {
            case id = "id"
            case parentId = "parentId"
            case path = "path"
            case pathPart = "pathPart"
            case resourceMethods = "resourceMethods"
        }
    }

    public struct Resources: AWSDecodableShape {
        /// The current page of elements from this collection.
        public let items: [Resource]?
        /// The current pagination position in the paged result set.
        public let position: String?

        @inlinable
        public init(items: [Resource]? = nil, position: String? = nil) {
            self.items = items
            self.position = position
        }

        private enum CodingKeys: String, CodingKey {
            case items = "item"
            case position = "position"
        }
    }

    public struct RestApi: AWSDecodableShape {
        /// The source of the API key for metering requests according to a usage plan. Valid values are: >HEADER to read the API key from the X-API-Key header of a request. AUTHORIZER to read the API key from the UsageIdentifierKey from a custom authorizer.
        public let apiKeySource: ApiKeySourceType?
        /// The list of binary media types supported by the RestApi. By default, the RestApi supports only UTF-8-encoded text payloads.
        public let binaryMediaTypes: [String]?
        /// The timestamp when the API was created.
        public let createdDate: Date?
        /// The API's description.
        public let description: String?
        /// Specifies whether clients can invoke your API by using the default execute-api endpoint. By default, clients can invoke your API with the default https://{api_id}.execute-api.{region}.amazonaws.com endpoint. To require that clients use a custom domain name to invoke your API, disable the default endpoint.
        public let disableExecuteApiEndpoint: Bool?
        /// The endpoint configuration of this RestApi showing the endpoint types and IP address types of the API.
        public let endpointConfiguration: EndpointConfiguration?
        /// The API's identifier. This identifier is unique across all of your APIs in API Gateway.
        public let id: String?
        /// A nullable integer that is used to enable compression (with non-negative between 0 and 10485760 (10M) bytes, inclusive) or disable compression (with a null value) on an API. When compression is enabled, compression or decompression is not applied on the payload if the payload size is smaller than this value. Setting it to zero allows compression for any payload size.
        public let minimumCompressionSize: Int?
        /// The API's name.
        public let name: String?
        /// A stringified JSON policy document that applies to this RestApi regardless of the caller and Method configuration.
        public let policy: String?
        /// The API's root resource ID.
        public let rootResourceId: String?
        /// The collection of tags. Each tag element is associated with a given resource.
        public let tags: [String: String]?
        /// A version identifier for the API.
        public let version: String?
        /// The warning messages reported when failonwarnings is turned on during API import.
        public let warnings: [String]?

        @inlinable
        public init(apiKeySource: ApiKeySourceType? = nil, binaryMediaTypes: [String]? = nil, createdDate: Date? = nil, description: String? = nil, disableExecuteApiEndpoint: Bool? = nil, endpointConfiguration: EndpointConfiguration? = nil, id: String? = nil, minimumCompressionSize: Int? = nil, name: String? = nil, policy: String? = nil, rootResourceId: String? = nil, tags: [String: String]? = nil, version: String? = nil, warnings: [String]? = nil) {
            self.apiKeySource = apiKeySource
            self.binaryMediaTypes = binaryMediaTypes
            self.createdDate = createdDate
            self.description = description
            self.disableExecuteApiEndpoint = disableExecuteApiEndpoint
            self.endpointConfiguration = endpointConfiguration
            self.id = id
            self.minimumCompressionSize = minimumCompressionSize
            self.name = name
            self.policy = policy
            self.rootResourceId = rootResourceId
            self.tags = tags
            self.version = version
            self.warnings = warnings
        }

        private enum CodingKeys: String, CodingKey {
            case apiKeySource = "apiKeySource"
            case binaryMediaTypes = "binaryMediaTypes"
            case createdDate = "createdDate"
            case description = "description"
            case disableExecuteApiEndpoint = "disableExecuteApiEndpoint"
            case endpointConfiguration = "endpointConfiguration"
            case id = "id"
            case minimumCompressionSize = "minimumCompressionSize"
            case name = "name"
            case policy = "policy"
            case rootResourceId = "rootResourceId"
            case tags = "tags"
            case version = "version"
            case warnings = "warnings"
        }
    }

    public struct RestApis: AWSDecodableShape {
        /// The current page of elements from this collection.
        public let items: [RestApi]?
        /// The current pagination position in the paged result set.
        public let position: String?

        @inlinable
        public init(items: [RestApi]? = nil, position: String? = nil) {
            self.items = items
            self.position = position
        }

        private enum CodingKeys: String, CodingKey {
            case items = "item"
            case position = "position"
        }
    }

    public struct SdkConfigurationProperty: AWSDecodableShape {
        /// The default value of an SdkType configuration property.
        public let defaultValue: String?
        /// The description of an SdkType configuration property.
        public let description: String?
        /// The user-friendly name of an SdkType configuration property.
        public let friendlyName: String?
        /// The name of a an SdkType configuration property.
        public let name: String?
        /// A boolean flag of an SdkType configuration property to indicate if the associated SDK configuration property is required (true) or not (false).
        public let required: Bool?

        @inlinable
        public init(defaultValue: String? = nil, description: String? = nil, friendlyName: String? = nil, name: String? = nil, required: Bool? = nil) {
            self.defaultValue = defaultValue
            self.description = description
            self.friendlyName = friendlyName
            self.name = name
            self.required = required
        }

        private enum CodingKeys: String, CodingKey {
            case defaultValue = "defaultValue"
            case description = "description"
            case friendlyName = "friendlyName"
            case name = "name"
            case required = "required"
        }
    }

    public struct SdkResponse: AWSDecodableShape {
        public static let _options: AWSShapeOptions = [.rawPayload]
        /// The binary blob response to GetSdk, which contains the generated SDK.
        public let body: AWSHTTPBody
        /// The content-disposition header value in the HTTP response.
        public let contentDisposition: String?
        /// The content-type header value in the HTTP response.
        public let contentType: String?

        @inlinable
        public init(body: AWSHTTPBody, contentDisposition: String? = nil, contentType: String? = nil) {
            self.body = body
            self.contentDisposition = contentDisposition
            self.contentType = contentType
        }

        public init(from decoder: Decoder) throws {
            let response = decoder.userInfo[.awsResponse]! as! ResponseDecodingContainer
            let container = try decoder.singleValueContainer()
            self.body = try container.decode(AWSHTTPBody.self)
            self.contentDisposition = try response.decodeHeaderIfPresent(String.self, key: "Content-Disposition")
            self.contentType = try response.decodeHeaderIfPresent(String.self, key: "Content-Type")
        }

        private enum CodingKeys: CodingKey {}
    }

    public struct SdkType: AWSDecodableShape {
        /// A list of configuration properties of an SdkType.
        public let configurationProperties: [SdkConfigurationProperty]?
        /// The description of an SdkType.
        public let description: String?
        /// The user-friendly name of an SdkType instance.
        public let friendlyName: String?
        /// The identifier of an SdkType instance.
        public let id: String?

        @inlinable
        public init(configurationProperties: [SdkConfigurationProperty]? = nil, description: String? = nil, friendlyName: String? = nil, id: String? = nil) {
            self.configurationProperties = configurationProperties
            self.description = description
            self.friendlyName = friendlyName
            self.id = id
        }

        private enum CodingKeys: String, CodingKey {
            case configurationProperties = "configurationProperties"
            case description = "description"
            case friendlyName = "friendlyName"
            case id = "id"
        }
    }

    public struct SdkTypes: AWSDecodableShape {
        /// The current page of elements from this collection.
        public let items: [SdkType]?

        @inlinable
        public init(items: [SdkType]? = nil) {
            self.items = items
        }

        private enum CodingKeys: String, CodingKey {
            case items = "item"
        }
    }

    public struct ServiceUnavailableException: AWSErrorShape {
        public let message: String?
        public let retryAfterSeconds: String?

        @inlinable
        public init(message: String? = nil, retryAfterSeconds: String? = nil) {
            self.message = message
            self.retryAfterSeconds = retryAfterSeconds
        }

        public init(from decoder: Decoder) throws {
            let response = decoder.userInfo[.awsResponse]! as! ResponseDecodingContainer
            let container = try decoder.container(keyedBy: CodingKeys.self)
            self.message = try container.decodeIfPresent(String.self, forKey: .message)
            self.retryAfterSeconds = try response.decodeHeaderIfPresent(String.self, key: "Retry-After")
        }

        private enum CodingKeys: String, CodingKey {
            case message = "message"
        }
    }

    public struct Stage: AWSDecodableShape {
        /// Settings for logging access in this stage.
        public let accessLogSettings: AccessLogSettings?
        /// Specifies whether a cache cluster is enabled for the stage. To activate a method-level cache, set CachingEnabled to true for a method.
        public let cacheClusterEnabled: Bool?
        /// The stage's cache capacity in GB. For more information about choosing a cache size, see Enabling API caching to enhance responsiveness.
        public let cacheClusterSize: CacheClusterSize?
        /// The status of the cache cluster for the stage, if enabled.
        public let cacheClusterStatus: CacheClusterStatus?
        /// Settings for the canary deployment in this stage.
        public let canarySettings: CanarySettings?
        /// The identifier of a client certificate for an API stage.
        public let clientCertificateId: String?
        /// The timestamp when the stage was created.
        public let createdDate: Date?
        /// The identifier of the Deployment that the stage points to.
        public let deploymentId: String?
        /// The stage's description.
        public let description: String?
        /// The version of the associated API documentation.
        public let documentationVersion: String?
        /// The timestamp when the stage last updated.
        public let lastUpdatedDate: Date?
        /// A map that defines the method settings for a Stage resource. Keys (designated as /{method_setting_key below) are method paths defined as {resource_path}/{http_method} for an individual method override, or /\*/\* for overriding all methods in the stage.
        public let methodSettings: [String: MethodSetting]?
        /// The name of the stage is the first path segment in the Uniform Resource Identifier (URI) of a call to API Gateway. Stage names can only contain alphanumeric characters, hyphens, and underscores. Maximum length is 128 characters.
        public let stageName: String?
        /// The collection of tags. Each tag element is associated with a given resource.
        public let tags: [String: String]?
        /// Specifies whether active tracing with X-ray is enabled for the Stage.
        public let tracingEnabled: Bool?
        /// A map that defines the stage variables for a Stage resource. Variable names can have alphanumeric and underscore characters, and the values must match [A-Za-z0-9-._~:/?#&=,]+.
        public let variables: [String: String]?
        /// The ARN of the WebAcl associated with the Stage.
        public let webAclArn: String?

        @inlinable
        public init(accessLogSettings: AccessLogSettings? = nil, cacheClusterEnabled: Bool? = nil, cacheClusterSize: CacheClusterSize? = nil, cacheClusterStatus: CacheClusterStatus? = nil, canarySettings: CanarySettings? = nil, clientCertificateId: String? = nil, createdDate: Date? = nil, deploymentId: String? = nil, description: String? = nil, documentationVersion: String? = nil, lastUpdatedDate: Date? = nil, methodSettings: [String: MethodSetting]? = nil, stageName: String? = nil, tags: [String: String]? = nil, tracingEnabled: Bool? = nil, variables: [String: String]? = nil, webAclArn: String? = nil) {
            self.accessLogSettings = accessLogSettings
            self.cacheClusterEnabled = cacheClusterEnabled
            self.cacheClusterSize = cacheClusterSize
            self.cacheClusterStatus = cacheClusterStatus
            self.canarySettings = canarySettings
            self.clientCertificateId = clientCertificateId
            self.createdDate = createdDate
            self.deploymentId = deploymentId
            self.description = description
            self.documentationVersion = documentationVersion
            self.lastUpdatedDate = lastUpdatedDate
            self.methodSettings = methodSettings
            self.stageName = stageName
            self.tags = tags
            self.tracingEnabled = tracingEnabled
            self.variables = variables
            self.webAclArn = webAclArn
        }

        private enum CodingKeys: String, CodingKey {
            case accessLogSettings = "accessLogSettings"
            case cacheClusterEnabled = "cacheClusterEnabled"
            case cacheClusterSize = "cacheClusterSize"
            case cacheClusterStatus = "cacheClusterStatus"
            case canarySettings = "canarySettings"
            case clientCertificateId = "clientCertificateId"
            case createdDate = "createdDate"
            case deploymentId = "deploymentId"
            case description = "description"
            case documentationVersion = "documentationVersion"
            case lastUpdatedDate = "lastUpdatedDate"
            case methodSettings = "methodSettings"
            case stageName = "stageName"
            case tags = "tags"
            case tracingEnabled = "tracingEnabled"
            case variables = "variables"
            case webAclArn = "webAclArn"
        }
    }

    public struct StageKey: AWSEncodableShape {
        /// The string identifier of the associated RestApi.
        public let restApiId: String?
        /// The stage name associated with the stage key.
        public let stageName: String?

        @inlinable
        public init(restApiId: String? = nil, stageName: String? = nil) {
            self.restApiId = restApiId
            self.stageName = stageName
        }

        private enum CodingKeys: String, CodingKey {
            case restApiId = "restApiId"
            case stageName = "stageName"
        }
    }

    public struct Stages: AWSDecodableShape {
        /// The current page of elements from this collection.
        public let item: [Stage]?

        @inlinable
        public init(item: [Stage]? = nil) {
            self.item = item
        }

        private enum CodingKeys: String, CodingKey {
            case item = "item"
        }
    }

    public struct TagResourceRequest: AWSEncodableShape {
        /// The ARN of a resource that can be tagged.
        public let resourceArn: String
        /// The key-value map of strings. The valid character set is [a-zA-Z+-=._:/]. The tag key can be up to 128 characters and must not start with aws:. The tag value can be up to 256 characters.
        public let tags: [String: String]

        @inlinable
        public init(resourceArn: String, tags: [String: String]) {
            self.resourceArn = resourceArn
            self.tags = tags
        }

        public func encode(to encoder: Encoder) throws {
            let request = encoder.userInfo[.awsRequest]! as! RequestEncodingContainer
            var container = encoder.container(keyedBy: CodingKeys.self)
            request.encodePath(self.resourceArn, key: "resourceArn")
            try container.encode(self.tags, forKey: .tags)
        }

        private enum CodingKeys: String, CodingKey {
            case tags = "tags"
        }
    }

    public struct Tags: AWSDecodableShape {
        /// The collection of tags. Each tag element is associated with a given resource.
        public let tags: [String: String]?

        @inlinable
        public init(tags: [String: String]? = nil) {
            self.tags = tags
        }

        private enum CodingKeys: String, CodingKey {
            case tags = "tags"
        }
    }

    public struct Template: AWSDecodableShape {
        /// The Apache Velocity Template Language (VTL) template content used for the template resource.
        public let value: String?

        @inlinable
        public init(value: String? = nil) {
            self.value = value
        }

        private enum CodingKeys: String, CodingKey {
            case value = "value"
        }
    }

    public struct TestInvokeAuthorizerRequest: AWSEncodableShape {
        /// A key-value map of additional context variables.
        public let additionalContext: [String: String]?
        /// Specifies a test invoke authorizer request's Authorizer ID.
        public let authorizerId: String
        /// The simulated request body of an incoming invocation request.
        public let body: String?
        /// A key-value map of headers to simulate an incoming invocation request. This is where the incoming authorization token, or identity source, should be specified.
        public let headers: [String: String]?
        /// The headers as a map from string to list of values to simulate an incoming invocation request. This is where the incoming authorization token, or identity source, may be specified.
        public let multiValueHeaders: [String: [String]]?
        /// The URI path, including query string, of the simulated invocation request. Use this to specify path parameters and query string parameters.
        public let pathWithQueryString: String?
        /// The string identifier of the associated RestApi.
        public let restApiId: String
        /// A key-value map of stage variables to simulate an invocation on a deployed Stage.
        public let stageVariables: [String: String]?

        @inlinable
        public init(additionalContext: [String: String]? = nil, authorizerId: String, body: String? = nil, headers: [String: String]? = nil, multiValueHeaders: [String: [String]]? = nil, pathWithQueryString: String? = nil, restApiId: String, stageVariables: [String: String]? = nil) {
            self.additionalContext = additionalContext
            self.authorizerId = authorizerId
            self.body = body
            self.headers = headers
            self.multiValueHeaders = multiValueHeaders
            self.pathWithQueryString = pathWithQueryString
            self.restApiId = restApiId
            self.stageVariables = stageVariables
        }

        public func encode(to encoder: Encoder) throws {
            let request = encoder.userInfo[.awsRequest]! as! RequestEncodingContainer
            var container = encoder.container(keyedBy: CodingKeys.self)
            try container.encodeIfPresent(self.additionalContext, forKey: .additionalContext)
            request.encodePath(self.authorizerId, key: "authorizerId")
            try container.encodeIfPresent(self.body, forKey: .body)
            try container.encodeIfPresent(self.headers, forKey: .headers)
            try container.encodeIfPresent(self.multiValueHeaders, forKey: .multiValueHeaders)
            try container.encodeIfPresent(self.pathWithQueryString, forKey: .pathWithQueryString)
            request.encodePath(self.restApiId, key: "restApiId")
            try container.encodeIfPresent(self.stageVariables, forKey: .stageVariables)
        }

        private enum CodingKeys: String, CodingKey {
            case additionalContext = "additionalContext"
            case body = "body"
            case headers = "headers"
            case multiValueHeaders = "multiValueHeaders"
            case pathWithQueryString = "pathWithQueryString"
            case stageVariables = "stageVariables"
        }
    }

    public struct TestInvokeAuthorizerResponse: AWSDecodableShape {
        /// The authorization response.
        public let authorization: [String: [String]]?
        /// The open identity claims, with any supported custom attributes, returned from the Cognito Your User Pool configured for the API.
        public let claims: [String: String]?
        /// The HTTP status code that the client would have received. Value is 0 if the authorizer succeeded.
        public let clientStatus: Int?
        /// The execution latency, in ms, of the test authorizer request.
        public let latency: Int64?
        /// The API Gateway execution log for the test authorizer request.
        public let log: String?
        /// The JSON policy document returned by the Authorizer
        public let policy: String?
        /// The principal identity returned by the Authorizer
        public let principalId: String?

        @inlinable
        public init(authorization: [String: [String]]? = nil, claims: [String: String]? = nil, clientStatus: Int? = nil, latency: Int64? = nil, log: String? = nil, policy: String? = nil, principalId: String? = nil) {
            self.authorization = authorization
            self.claims = claims
            self.clientStatus = clientStatus
            self.latency = latency
            self.log = log
            self.policy = policy
            self.principalId = principalId
        }

        private enum CodingKeys: String, CodingKey {
            case authorization = "authorization"
            case claims = "claims"
            case clientStatus = "clientStatus"
            case latency = "latency"
            case log = "log"
            case policy = "policy"
            case principalId = "principalId"
        }
    }

    public struct TestInvokeMethodRequest: AWSEncodableShape {
        /// The simulated request body of an incoming invocation request.
        public let body: String?
        /// A ClientCertificate identifier to use in the test invocation. API Gateway will use the certificate when making the HTTPS request to the defined back-end endpoint.
        public let clientCertificateId: String?
        /// A key-value map of headers to simulate an incoming invocation request.
        public let headers: [String: String]?
        /// Specifies a test invoke method request's HTTP method.
        public let httpMethod: String
        /// The headers as a map from string to list of values to simulate an incoming invocation request.
        public let multiValueHeaders: [String: [String]]?
        /// The URI path, including query string, of the simulated invocation request. Use this to specify path parameters and query string parameters.
        public let pathWithQueryString: String?
        /// Specifies a test invoke method request's resource ID.
        public let resourceId: String
        /// The string identifier of the associated RestApi.
        public let restApiId: String
        /// A key-value map of stage variables to simulate an invocation on a deployed Stage.
        public let stageVariables: [String: String]?

        @inlinable
        public init(body: String? = nil, clientCertificateId: String? = nil, headers: [String: String]? = nil, httpMethod: String, multiValueHeaders: [String: [String]]? = nil, pathWithQueryString: String? = nil, resourceId: String, restApiId: String, stageVariables: [String: String]? = nil) {
            self.body = body
            self.clientCertificateId = clientCertificateId
            self.headers = headers
            self.httpMethod = httpMethod
            self.multiValueHeaders = multiValueHeaders
            self.pathWithQueryString = pathWithQueryString
            self.resourceId = resourceId
            self.restApiId = restApiId
            self.stageVariables = stageVariables
        }

        public func encode(to encoder: Encoder) throws {
            let request = encoder.userInfo[.awsRequest]! as! RequestEncodingContainer
            var container = encoder.container(keyedBy: CodingKeys.self)
            try container.encodeIfPresent(self.body, forKey: .body)
            try container.encodeIfPresent(self.clientCertificateId, forKey: .clientCertificateId)
            try container.encodeIfPresent(self.headers, forKey: .headers)
            request.encodePath(self.httpMethod, key: "httpMethod")
            try container.encodeIfPresent(self.multiValueHeaders, forKey: .multiValueHeaders)
            try container.encodeIfPresent(self.pathWithQueryString, forKey: .pathWithQueryString)
            request.encodePath(self.resourceId, key: "resourceId")
            request.encodePath(self.restApiId, key: "restApiId")
            try container.encodeIfPresent(self.stageVariables, forKey: .stageVariables)
        }

        private enum CodingKeys: String, CodingKey {
            case body = "body"
            case clientCertificateId = "clientCertificateId"
            case headers = "headers"
            case multiValueHeaders = "multiValueHeaders"
            case pathWithQueryString = "pathWithQueryString"
            case stageVariables = "stageVariables"
        }
    }

    public struct TestInvokeMethodResponse: AWSDecodableShape {
        /// The body of the HTTP response.
        public let body: String?
        /// The headers of the HTTP response.
        public let headers: [String: String]?
        /// The execution latency, in ms, of the test invoke request.
        public let latency: Int64?
        /// The API Gateway execution log for the test invoke request.
        public let log: String?
        /// The headers of the HTTP response as a map from string to list of values.
        public let multiValueHeaders: [String: [String]]?
        /// The HTTP status code.
        public let status: Int?

        @inlinable
        public init(body: String? = nil, headers: [String: String]? = nil, latency: Int64? = nil, log: String? = nil, multiValueHeaders: [String: [String]]? = nil, status: Int? = nil) {
            self.body = body
            self.headers = headers
            self.latency = latency
            self.log = log
            self.multiValueHeaders = multiValueHeaders
            self.status = status
        }

        private enum CodingKeys: String, CodingKey {
            case body = "body"
            case headers = "headers"
            case latency = "latency"
            case log = "log"
            case multiValueHeaders = "multiValueHeaders"
            case status = "status"
        }
    }

    public struct ThrottleSettings: AWSEncodableShape & AWSDecodableShape {
        /// The API target request burst rate limit. This allows more requests through for a period of time than the target rate limit.
        public let burstLimit: Int?
        /// The API target request rate limit.
        public let rateLimit: Double?

        @inlinable
        public init(burstLimit: Int? = nil, rateLimit: Double? = nil) {
            self.burstLimit = burstLimit
            self.rateLimit = rateLimit
        }

        private enum CodingKeys: String, CodingKey {
            case burstLimit = "burstLimit"
            case rateLimit = "rateLimit"
        }
    }

    public struct TlsConfig: AWSEncodableShape & AWSDecodableShape {
        /// Specifies whether or not API Gateway skips verification that the certificate for an integration endpoint is issued by a supported certificate authority. This isn’t recommended, but it enables you to use certificates that are signed by private certificate authorities, or certificates that are self-signed. If enabled, API Gateway still performs basic certificate validation, which includes checking the certificate's expiration date, hostname, and presence of a root certificate authority. Supported only for HTTP and HTTP_PROXY integrations.  Enabling insecureSkipVerification isn't recommended, especially for integrations with public HTTPS endpoints. If you enable insecureSkipVerification, you increase the risk of man-in-the-middle attacks.
        public let insecureSkipVerification: Bool?

        @inlinable
        public init(insecureSkipVerification: Bool? = nil) {
            self.insecureSkipVerification = insecureSkipVerification
        }

        private enum CodingKeys: String, CodingKey {
            case insecureSkipVerification = "insecureSkipVerification"
        }
    }

    public struct TooManyRequestsException: AWSErrorShape {
        public let message: String?
        public let retryAfterSeconds: String?

        @inlinable
        public init(message: String? = nil, retryAfterSeconds: String? = nil) {
            self.message = message
            self.retryAfterSeconds = retryAfterSeconds
        }

        public init(from decoder: Decoder) throws {
            let response = decoder.userInfo[.awsResponse]! as! ResponseDecodingContainer
            let container = try decoder.container(keyedBy: CodingKeys.self)
            self.message = try container.decodeIfPresent(String.self, forKey: .message)
            self.retryAfterSeconds = try response.decodeHeaderIfPresent(String.self, key: "Retry-After")
        }

        private enum CodingKeys: String, CodingKey {
            case message = "message"
        }
    }

    public struct UntagResourceRequest: AWSEncodableShape {
        /// The ARN of a resource that can be tagged.
        public let resourceArn: String
        /// The Tag keys to delete.
        public let tagKeys: [String]

        @inlinable
        public init(resourceArn: String, tagKeys: [String]) {
            self.resourceArn = resourceArn
            self.tagKeys = tagKeys
        }

        public func encode(to encoder: Encoder) throws {
            let request = encoder.userInfo[.awsRequest]! as! RequestEncodingContainer
            _ = encoder.container(keyedBy: CodingKeys.self)
            request.encodePath(self.resourceArn, key: "resourceArn")
            request.encodeQuery(self.tagKeys, key: "tagKeys")
        }

        private enum CodingKeys: CodingKey {}
    }

    public struct UpdateAccountRequest: AWSEncodableShape {
        /// For more information about supported patch operations, see Patch Operations.
        public let patchOperations: [PatchOperation]?

        @inlinable
        public init(patchOperations: [PatchOperation]? = nil) {
            self.patchOperations = patchOperations
        }

        private enum CodingKeys: String, CodingKey {
            case patchOperations = "patchOperations"
        }
    }

    public struct UpdateApiKeyRequest: AWSEncodableShape {
        /// The identifier of the ApiKey resource to be updated.
        public let apiKey: String
        /// For more information about supported patch operations, see Patch Operations.
        public let patchOperations: [PatchOperation]?

        @inlinable
        public init(apiKey: String, patchOperations: [PatchOperation]? = nil) {
            self.apiKey = apiKey
            self.patchOperations = patchOperations
        }

        public func encode(to encoder: Encoder) throws {
            let request = encoder.userInfo[.awsRequest]! as! RequestEncodingContainer
            var container = encoder.container(keyedBy: CodingKeys.self)
            request.encodePath(self.apiKey, key: "apiKey")
            try container.encodeIfPresent(self.patchOperations, forKey: .patchOperations)
        }

        private enum CodingKeys: String, CodingKey {
            case patchOperations = "patchOperations"
        }
    }

    public struct UpdateAuthorizerRequest: AWSEncodableShape {
        /// The identifier of the Authorizer resource.
        public let authorizerId: String
        /// For more information about supported patch operations, see Patch Operations.
        public let patchOperations: [PatchOperation]?
        /// The string identifier of the associated RestApi.
        public let restApiId: String

        @inlinable
        public init(authorizerId: String, patchOperations: [PatchOperation]? = nil, restApiId: String) {
            self.authorizerId = authorizerId
            self.patchOperations = patchOperations
            self.restApiId = restApiId
        }

        public func encode(to encoder: Encoder) throws {
            let request = encoder.userInfo[.awsRequest]! as! RequestEncodingContainer
            var container = encoder.container(keyedBy: CodingKeys.self)
            request.encodePath(self.authorizerId, key: "authorizerId")
            try container.encodeIfPresent(self.patchOperations, forKey: .patchOperations)
            request.encodePath(self.restApiId, key: "restApiId")
        }

        private enum CodingKeys: String, CodingKey {
            case patchOperations = "patchOperations"
        }
    }

    public struct UpdateBasePathMappingRequest: AWSEncodableShape {
        /// The base path of the BasePathMapping resource to change. To specify an empty base path, set this parameter to '(none)'.
        public let basePath: String
        /// The domain name of the BasePathMapping resource to change.
        public let domainName: String
        ///  The identifier for the domain name resource. Supported only for private custom domain names.
        public let domainNameId: String?
        /// For more information about supported patch operations, see Patch Operations.
        public let patchOperations: [PatchOperation]?

        @inlinable
        public init(basePath: String, domainName: String, domainNameId: String? = nil, patchOperations: [PatchOperation]? = nil) {
            self.basePath = basePath
            self.domainName = domainName
            self.domainNameId = domainNameId
            self.patchOperations = patchOperations
        }

        public func encode(to encoder: Encoder) throws {
            let request = encoder.userInfo[.awsRequest]! as! RequestEncodingContainer
            var container = encoder.container(keyedBy: CodingKeys.self)
            request.encodePath(self.basePath, key: "basePath")
            request.encodePath(self.domainName, key: "domainName")
            request.encodeQuery(self.domainNameId, key: "domainNameId")
            try container.encodeIfPresent(self.patchOperations, forKey: .patchOperations)
        }

        private enum CodingKeys: String, CodingKey {
            case patchOperations = "patchOperations"
        }
    }

    public struct UpdateClientCertificateRequest: AWSEncodableShape {
        /// The identifier of the ClientCertificate resource to be updated.
        public let clientCertificateId: String
        /// For more information about supported patch operations, see Patch Operations.
        public let patchOperations: [PatchOperation]?

        @inlinable
        public init(clientCertificateId: String, patchOperations: [PatchOperation]? = nil) {
            self.clientCertificateId = clientCertificateId
            self.patchOperations = patchOperations
        }

        public func encode(to encoder: Encoder) throws {
            let request = encoder.userInfo[.awsRequest]! as! RequestEncodingContainer
            var container = encoder.container(keyedBy: CodingKeys.self)
            request.encodePath(self.clientCertificateId, key: "clientCertificateId")
            try container.encodeIfPresent(self.patchOperations, forKey: .patchOperations)
        }

        private enum CodingKeys: String, CodingKey {
            case patchOperations = "patchOperations"
        }
    }

    public struct UpdateDeploymentRequest: AWSEncodableShape {
        /// The replacement identifier for the Deployment resource to change information about.
        public let deploymentId: String
        /// For more information about supported patch operations, see Patch Operations.
        public let patchOperations: [PatchOperation]?
        /// The string identifier of the associated RestApi.
        public let restApiId: String

        @inlinable
        public init(deploymentId: String, patchOperations: [PatchOperation]? = nil, restApiId: String) {
            self.deploymentId = deploymentId
            self.patchOperations = patchOperations
            self.restApiId = restApiId
        }

        public func encode(to encoder: Encoder) throws {
            let request = encoder.userInfo[.awsRequest]! as! RequestEncodingContainer
            var container = encoder.container(keyedBy: CodingKeys.self)
            request.encodePath(self.deploymentId, key: "deploymentId")
            try container.encodeIfPresent(self.patchOperations, forKey: .patchOperations)
            request.encodePath(self.restApiId, key: "restApiId")
        }

        private enum CodingKeys: String, CodingKey {
            case patchOperations = "patchOperations"
        }
    }

    public struct UpdateDocumentationPartRequest: AWSEncodableShape {
        /// The identifier of the to-be-updated documentation part.
        public let documentationPartId: String
        /// For more information about supported patch operations, see Patch Operations.
        public let patchOperations: [PatchOperation]?
        /// The string identifier of the associated RestApi.
        public let restApiId: String

        @inlinable
        public init(documentationPartId: String, patchOperations: [PatchOperation]? = nil, restApiId: String) {
            self.documentationPartId = documentationPartId
            self.patchOperations = patchOperations
            self.restApiId = restApiId
        }

        public func encode(to encoder: Encoder) throws {
            let request = encoder.userInfo[.awsRequest]! as! RequestEncodingContainer
            var container = encoder.container(keyedBy: CodingKeys.self)
            request.encodePath(self.documentationPartId, key: "documentationPartId")
            try container.encodeIfPresent(self.patchOperations, forKey: .patchOperations)
            request.encodePath(self.restApiId, key: "restApiId")
        }

        private enum CodingKeys: String, CodingKey {
            case patchOperations = "patchOperations"
        }
    }

    public struct UpdateDocumentationVersionRequest: AWSEncodableShape {
        /// The version identifier of the to-be-updated documentation version.
        public let documentationVersion: String
        /// For more information about supported patch operations, see Patch Operations.
        public let patchOperations: [PatchOperation]?
        /// The string identifier of the associated RestApi.
        public let restApiId: String

        @inlinable
        public init(documentationVersion: String, patchOperations: [PatchOperation]? = nil, restApiId: String) {
            self.documentationVersion = documentationVersion
            self.patchOperations = patchOperations
            self.restApiId = restApiId
        }

        public func encode(to encoder: Encoder) throws {
            let request = encoder.userInfo[.awsRequest]! as! RequestEncodingContainer
            var container = encoder.container(keyedBy: CodingKeys.self)
            request.encodePath(self.documentationVersion, key: "documentationVersion")
            try container.encodeIfPresent(self.patchOperations, forKey: .patchOperations)
            request.encodePath(self.restApiId, key: "restApiId")
        }

        private enum CodingKeys: String, CodingKey {
            case patchOperations = "patchOperations"
        }
    }

    public struct UpdateDomainNameRequest: AWSEncodableShape {
        /// The name of the DomainName resource to be changed.
        public let domainName: String
        ///  The identifier for the domain name resource. Supported only for private custom domain names.
        public let domainNameId: String?
        /// For more information about supported patch operations, see Patch Operations.
        public let patchOperations: [PatchOperation]?

        @inlinable
        public init(domainName: String, domainNameId: String? = nil, patchOperations: [PatchOperation]? = nil) {
            self.domainName = domainName
            self.domainNameId = domainNameId
            self.patchOperations = patchOperations
        }

        public func encode(to encoder: Encoder) throws {
            let request = encoder.userInfo[.awsRequest]! as! RequestEncodingContainer
            var container = encoder.container(keyedBy: CodingKeys.self)
            request.encodePath(self.domainName, key: "domainName")
            request.encodeQuery(self.domainNameId, key: "domainNameId")
            try container.encodeIfPresent(self.patchOperations, forKey: .patchOperations)
        }

        private enum CodingKeys: String, CodingKey {
            case patchOperations = "patchOperations"
        }
    }

    public struct UpdateGatewayResponseRequest: AWSEncodableShape {
        /// For more information about supported patch operations, see Patch Operations.
        public let patchOperations: [PatchOperation]?
        /// The response type of the associated GatewayResponse.
        public let responseType: GatewayResponseType
        /// The string identifier of the associated RestApi.
        public let restApiId: String

        @inlinable
        public init(patchOperations: [PatchOperation]? = nil, responseType: GatewayResponseType, restApiId: String) {
            self.patchOperations = patchOperations
            self.responseType = responseType
            self.restApiId = restApiId
        }

        public func encode(to encoder: Encoder) throws {
            let request = encoder.userInfo[.awsRequest]! as! RequestEncodingContainer
            var container = encoder.container(keyedBy: CodingKeys.self)
            try container.encodeIfPresent(self.patchOperations, forKey: .patchOperations)
            request.encodePath(self.responseType, key: "responseType")
            request.encodePath(self.restApiId, key: "restApiId")
        }

        private enum CodingKeys: String, CodingKey {
            case patchOperations = "patchOperations"
        }
    }

    public struct UpdateIntegrationRequest: AWSEncodableShape {
        /// Represents an update integration request's HTTP method.
        public let httpMethod: String
        /// For more information about supported patch operations, see Patch Operations.
        public let patchOperations: [PatchOperation]?
        /// Represents an update integration request's resource identifier.
        public let resourceId: String
        /// The string identifier of the associated RestApi.
        public let restApiId: String

        @inlinable
        public init(httpMethod: String, patchOperations: [PatchOperation]? = nil, resourceId: String, restApiId: String) {
            self.httpMethod = httpMethod
            self.patchOperations = patchOperations
            self.resourceId = resourceId
            self.restApiId = restApiId
        }

        public func encode(to encoder: Encoder) throws {
            let request = encoder.userInfo[.awsRequest]! as! RequestEncodingContainer
            var container = encoder.container(keyedBy: CodingKeys.self)
            request.encodePath(self.httpMethod, key: "httpMethod")
            try container.encodeIfPresent(self.patchOperations, forKey: .patchOperations)
            request.encodePath(self.resourceId, key: "resourceId")
            request.encodePath(self.restApiId, key: "restApiId")
        }

        private enum CodingKeys: String, CodingKey {
            case patchOperations = "patchOperations"
        }
    }

    public struct UpdateIntegrationResponseRequest: AWSEncodableShape {
        /// Specifies an update integration response request's HTTP method.
        public let httpMethod: String
        /// For more information about supported patch operations, see Patch Operations.
        public let patchOperations: [PatchOperation]?
        /// Specifies an update integration response request's resource identifier.
        public let resourceId: String
        /// The string identifier of the associated RestApi.
        public let restApiId: String
        /// Specifies an update integration response request's status code.
        public let statusCode: String

        @inlinable
        public init(httpMethod: String, patchOperations: [PatchOperation]? = nil, resourceId: String, restApiId: String, statusCode: String) {
            self.httpMethod = httpMethod
            self.patchOperations = patchOperations
            self.resourceId = resourceId
            self.restApiId = restApiId
            self.statusCode = statusCode
        }

        public func encode(to encoder: Encoder) throws {
            let request = encoder.userInfo[.awsRequest]! as! RequestEncodingContainer
            var container = encoder.container(keyedBy: CodingKeys.self)
            request.encodePath(self.httpMethod, key: "httpMethod")
            try container.encodeIfPresent(self.patchOperations, forKey: .patchOperations)
            request.encodePath(self.resourceId, key: "resourceId")
            request.encodePath(self.restApiId, key: "restApiId")
            request.encodePath(self.statusCode, key: "statusCode")
        }

        public func validate(name: String) throws {
            try self.validate(self.statusCode, name: "statusCode", parent: name, pattern: "^[1-5]\\d\\d$")
        }

        private enum CodingKeys: String, CodingKey {
            case patchOperations = "patchOperations"
        }
    }

    public struct UpdateMethodRequest: AWSEncodableShape {
        /// The HTTP verb of the Method resource.
        public let httpMethod: String
        /// For more information about supported patch operations, see Patch Operations.
        public let patchOperations: [PatchOperation]?
        /// The Resource identifier for the Method resource.
        public let resourceId: String
        /// The string identifier of the associated RestApi.
        public let restApiId: String

        @inlinable
        public init(httpMethod: String, patchOperations: [PatchOperation]? = nil, resourceId: String, restApiId: String) {
            self.httpMethod = httpMethod
            self.patchOperations = patchOperations
            self.resourceId = resourceId
            self.restApiId = restApiId
        }

        public func encode(to encoder: Encoder) throws {
            let request = encoder.userInfo[.awsRequest]! as! RequestEncodingContainer
            var container = encoder.container(keyedBy: CodingKeys.self)
            request.encodePath(self.httpMethod, key: "httpMethod")
            try container.encodeIfPresent(self.patchOperations, forKey: .patchOperations)
            request.encodePath(self.resourceId, key: "resourceId")
            request.encodePath(self.restApiId, key: "restApiId")
        }

        private enum CodingKeys: String, CodingKey {
            case patchOperations = "patchOperations"
        }
    }

    public struct UpdateMethodResponseRequest: AWSEncodableShape {
        /// The HTTP verb of the Method resource.
        public let httpMethod: String
        /// For more information about supported patch operations, see Patch Operations.
        public let patchOperations: [PatchOperation]?
        /// The Resource identifier for the MethodResponse resource.
        public let resourceId: String
        /// The string identifier of the associated RestApi.
        public let restApiId: String
        /// The status code for the MethodResponse resource.
        public let statusCode: String

        @inlinable
        public init(httpMethod: String, patchOperations: [PatchOperation]? = nil, resourceId: String, restApiId: String, statusCode: String) {
            self.httpMethod = httpMethod
            self.patchOperations = patchOperations
            self.resourceId = resourceId
            self.restApiId = restApiId
            self.statusCode = statusCode
        }

        public func encode(to encoder: Encoder) throws {
            let request = encoder.userInfo[.awsRequest]! as! RequestEncodingContainer
            var container = encoder.container(keyedBy: CodingKeys.self)
            request.encodePath(self.httpMethod, key: "httpMethod")
            try container.encodeIfPresent(self.patchOperations, forKey: .patchOperations)
            request.encodePath(self.resourceId, key: "resourceId")
            request.encodePath(self.restApiId, key: "restApiId")
            request.encodePath(self.statusCode, key: "statusCode")
        }

        public func validate(name: String) throws {
            try self.validate(self.statusCode, name: "statusCode", parent: name, pattern: "^[1-5]\\d\\d$")
        }

        private enum CodingKeys: String, CodingKey {
            case patchOperations = "patchOperations"
        }
    }

    public struct UpdateModelRequest: AWSEncodableShape {
        /// The name of the model to update.
        public let modelName: String
        /// For more information about supported patch operations, see Patch Operations.
        public let patchOperations: [PatchOperation]?
        /// The string identifier of the associated RestApi.
        public let restApiId: String

        @inlinable
        public init(modelName: String, patchOperations: [PatchOperation]? = nil, restApiId: String) {
            self.modelName = modelName
            self.patchOperations = patchOperations
            self.restApiId = restApiId
        }

        public func encode(to encoder: Encoder) throws {
            let request = encoder.userInfo[.awsRequest]! as! RequestEncodingContainer
            var container = encoder.container(keyedBy: CodingKeys.self)
            request.encodePath(self.modelName, key: "modelName")
            try container.encodeIfPresent(self.patchOperations, forKey: .patchOperations)
            request.encodePath(self.restApiId, key: "restApiId")
        }

        private enum CodingKeys: String, CodingKey {
            case patchOperations = "patchOperations"
        }
    }

    public struct UpdateRequestValidatorRequest: AWSEncodableShape {
        /// For more information about supported patch operations, see Patch Operations.
        public let patchOperations: [PatchOperation]?
        /// The identifier of RequestValidator to be updated.
        public let requestValidatorId: String
        /// The string identifier of the associated RestApi.
        public let restApiId: String

        @inlinable
        public init(patchOperations: [PatchOperation]? = nil, requestValidatorId: String, restApiId: String) {
            self.patchOperations = patchOperations
            self.requestValidatorId = requestValidatorId
            self.restApiId = restApiId
        }

        public func encode(to encoder: Encoder) throws {
            let request = encoder.userInfo[.awsRequest]! as! RequestEncodingContainer
            var container = encoder.container(keyedBy: CodingKeys.self)
            try container.encodeIfPresent(self.patchOperations, forKey: .patchOperations)
            request.encodePath(self.requestValidatorId, key: "requestValidatorId")
            request.encodePath(self.restApiId, key: "restApiId")
        }

        private enum CodingKeys: String, CodingKey {
            case patchOperations = "patchOperations"
        }
    }

    public struct UpdateResourceRequest: AWSEncodableShape {
        /// For more information about supported patch operations, see Patch Operations.
        public let patchOperations: [PatchOperation]?
        /// The identifier of the Resource resource.
        public let resourceId: String
        /// The string identifier of the associated RestApi.
        public let restApiId: String

        @inlinable
        public init(patchOperations: [PatchOperation]? = nil, resourceId: String, restApiId: String) {
            self.patchOperations = patchOperations
            self.resourceId = resourceId
            self.restApiId = restApiId
        }

        public func encode(to encoder: Encoder) throws {
            let request = encoder.userInfo[.awsRequest]! as! RequestEncodingContainer
            var container = encoder.container(keyedBy: CodingKeys.self)
            try container.encodeIfPresent(self.patchOperations, forKey: .patchOperations)
            request.encodePath(self.resourceId, key: "resourceId")
            request.encodePath(self.restApiId, key: "restApiId")
        }

        private enum CodingKeys: String, CodingKey {
            case patchOperations = "patchOperations"
        }
    }

    public struct UpdateRestApiRequest: AWSEncodableShape {
        /// For more information about supported patch operations, see Patch Operations.
        public let patchOperations: [PatchOperation]?
        /// The string identifier of the associated RestApi.
        public let restApiId: String

        @inlinable
        public init(patchOperations: [PatchOperation]? = nil, restApiId: String) {
            self.patchOperations = patchOperations
            self.restApiId = restApiId
        }

        public func encode(to encoder: Encoder) throws {
            let request = encoder.userInfo[.awsRequest]! as! RequestEncodingContainer
            var container = encoder.container(keyedBy: CodingKeys.self)
            try container.encodeIfPresent(self.patchOperations, forKey: .patchOperations)
            request.encodePath(self.restApiId, key: "restApiId")
        }

        private enum CodingKeys: String, CodingKey {
            case patchOperations = "patchOperations"
        }
    }

    public struct UpdateStageRequest: AWSEncodableShape {
        /// For more information about supported patch operations, see Patch Operations.
        public let patchOperations: [PatchOperation]?
        /// The string identifier of the associated RestApi.
        public let restApiId: String
        /// The name of the Stage resource to change information about.
        public let stageName: String

        @inlinable
        public init(patchOperations: [PatchOperation]? = nil, restApiId: String, stageName: String) {
            self.patchOperations = patchOperations
            self.restApiId = restApiId
            self.stageName = stageName
        }

        public func encode(to encoder: Encoder) throws {
            let request = encoder.userInfo[.awsRequest]! as! RequestEncodingContainer
            var container = encoder.container(keyedBy: CodingKeys.self)
            try container.encodeIfPresent(self.patchOperations, forKey: .patchOperations)
            request.encodePath(self.restApiId, key: "restApiId")
            request.encodePath(self.stageName, key: "stageName")
        }

        private enum CodingKeys: String, CodingKey {
            case patchOperations = "patchOperations"
        }
    }

    public struct UpdateUsagePlanRequest: AWSEncodableShape {
        /// For more information about supported patch operations, see Patch Operations.
        public let patchOperations: [PatchOperation]?
        /// The Id of the to-be-updated usage plan.
        public let usagePlanId: String

        @inlinable
        public init(patchOperations: [PatchOperation]? = nil, usagePlanId: String) {
            self.patchOperations = patchOperations
            self.usagePlanId = usagePlanId
        }

        public func encode(to encoder: Encoder) throws {
            let request = encoder.userInfo[.awsRequest]! as! RequestEncodingContainer
            var container = encoder.container(keyedBy: CodingKeys.self)
            try container.encodeIfPresent(self.patchOperations, forKey: .patchOperations)
            request.encodePath(self.usagePlanId, key: "usagePlanId")
        }

        private enum CodingKeys: String, CodingKey {
            case patchOperations = "patchOperations"
        }
    }

    public struct UpdateUsageRequest: AWSEncodableShape {
        /// The identifier of the API key associated with the usage plan in which a temporary extension is granted to the remaining quota.
        public let keyId: String
        /// For more information about supported patch operations, see Patch Operations.
        public let patchOperations: [PatchOperation]?
        /// The Id of the usage plan associated with the usage data.
        public let usagePlanId: String

        @inlinable
        public init(keyId: String, patchOperations: [PatchOperation]? = nil, usagePlanId: String) {
            self.keyId = keyId
            self.patchOperations = patchOperations
            self.usagePlanId = usagePlanId
        }

        public func encode(to encoder: Encoder) throws {
            let request = encoder.userInfo[.awsRequest]! as! RequestEncodingContainer
            var container = encoder.container(keyedBy: CodingKeys.self)
            request.encodePath(self.keyId, key: "keyId")
            try container.encodeIfPresent(self.patchOperations, forKey: .patchOperations)
            request.encodePath(self.usagePlanId, key: "usagePlanId")
        }

        private enum CodingKeys: String, CodingKey {
            case patchOperations = "patchOperations"
        }
    }

    public struct UpdateVpcLinkRequest: AWSEncodableShape {
        /// For more information about supported patch operations, see Patch Operations.
        public let patchOperations: [PatchOperation]?
        /// The identifier of the  VpcLink. It is used in an Integration to reference this VpcLink.
        public let vpcLinkId: String

        @inlinable
        public init(patchOperations: [PatchOperation]? = nil, vpcLinkId: String) {
            self.patchOperations = patchOperations
            self.vpcLinkId = vpcLinkId
        }

        public func encode(to encoder: Encoder) throws {
            let request = encoder.userInfo[.awsRequest]! as! RequestEncodingContainer
            var container = encoder.container(keyedBy: CodingKeys.self)
            try container.encodeIfPresent(self.patchOperations, forKey: .patchOperations)
            request.encodePath(self.vpcLinkId, key: "vpcLinkId")
        }

        private enum CodingKeys: String, CodingKey {
            case patchOperations = "patchOperations"
        }
    }

    public struct Usage: AWSDecodableShape {
        /// The ending date of the usage data.
        public let endDate: String?
        /// The usage data, as daily logs of used and remaining quotas, over the specified time interval indexed over the API keys in a usage plan. For example, {..., "values" : { "{api_key}" : [ [0, 100], [10, 90], [100, 10]]}, where {api_key} stands for an API key value and the daily log entry is of the format [used quota, remaining quota].
        public let items: [String: [[Int64]]]?
        /// The current pagination position in the paged result set.
        public let position: String?
        /// The starting date of the usage data.
        public let startDate: String?
        /// The plan Id associated with this usage data.
        public let usagePlanId: String?

        @inlinable
        public init(endDate: String? = nil, items: [String: [[Int64]]]? = nil, position: String? = nil, startDate: String? = nil, usagePlanId: String? = nil) {
            self.endDate = endDate
            self.items = items
            self.position = position
            self.startDate = startDate
            self.usagePlanId = usagePlanId
        }

        private enum CodingKeys: String, CodingKey {
            case endDate = "endDate"
            case items = "values"
            case position = "position"
            case startDate = "startDate"
            case usagePlanId = "usagePlanId"
        }
    }

    public struct UsagePlan: AWSDecodableShape {
        /// The associated API stages of a usage plan.
        public let apiStages: [ApiStage]?
        /// The description of a usage plan.
        public let description: String?
        /// The identifier of a UsagePlan resource.
        public let id: String?
        /// The name of a usage plan.
        public let name: String?
        /// The Amazon Web Services Marketplace product identifier to associate with the usage plan as a SaaS product on the Amazon Web Services Marketplace.
        public let productCode: String?
        /// The target maximum number of permitted requests per a given unit time interval.
        public let quota: QuotaSettings?
        /// The collection of tags. Each tag element is associated with a given resource.
        public let tags: [String: String]?
        /// A map containing method level throttling information for API stage in a usage plan.
        public let throttle: ThrottleSettings?

        @inlinable
        public init(apiStages: [ApiStage]? = nil, description: String? = nil, id: String? = nil, name: String? = nil, productCode: String? = nil, quota: QuotaSettings? = nil, tags: [String: String]? = nil, throttle: ThrottleSettings? = nil) {
            self.apiStages = apiStages
            self.description = description
            self.id = id
            self.name = name
            self.productCode = productCode
            self.quota = quota
            self.tags = tags
            self.throttle = throttle
        }

        private enum CodingKeys: String, CodingKey {
            case apiStages = "apiStages"
            case description = "description"
            case id = "id"
            case name = "name"
            case productCode = "productCode"
            case quota = "quota"
            case tags = "tags"
            case throttle = "throttle"
        }
    }

    public struct UsagePlanKey: AWSDecodableShape {
        /// The Id of a usage plan key.
        public let id: String?
        /// The name of a usage plan key.
        public let name: String?
        /// The type of a usage plan key. Currently, the valid key type is API_KEY.
        public let type: String?
        /// The value of a usage plan key.
        public let value: String?

        @inlinable
        public init(id: String? = nil, name: String? = nil, type: String? = nil, value: String? = nil) {
            self.id = id
            self.name = name
            self.type = type
            self.value = value
        }

        private enum CodingKeys: String, CodingKey {
            case id = "id"
            case name = "name"
            case type = "type"
            case value = "value"
        }
    }

    public struct UsagePlanKeys: AWSDecodableShape {
        /// The current page of elements from this collection.
        public let items: [UsagePlanKey]?
        /// The current pagination position in the paged result set.
        public let position: String?

        @inlinable
        public init(items: [UsagePlanKey]? = nil, position: String? = nil) {
            self.items = items
            self.position = position
        }

        private enum CodingKeys: String, CodingKey {
            case items = "item"
            case position = "position"
        }
    }

    public struct UsagePlans: AWSDecodableShape {
        /// The current page of elements from this collection.
        public let items: [UsagePlan]?
        /// The current pagination position in the paged result set.
        public let position: String?

        @inlinable
        public init(items: [UsagePlan]? = nil, position: String? = nil) {
            self.items = items
            self.position = position
        }

        private enum CodingKeys: String, CodingKey {
            case items = "item"
            case position = "position"
        }
    }

    public struct VpcLink: AWSDecodableShape {
        /// The description of the VPC link.
        public let description: String?
        /// The identifier of the  VpcLink. It is used in an Integration to reference this VpcLink.
        public let id: String?
        /// The name used to label and identify the VPC link.
        public let name: String?
        /// The status of the VPC link. The valid values are AVAILABLE, PENDING, DELETING, or FAILED. Deploying an API will wait if the status is PENDING and will fail if the status is DELETING.
        public let status: VpcLinkStatus?
        /// A description about the VPC link status.
        public let statusMessage: String?
        /// The collection of tags. Each tag element is associated with a given resource.
        public let tags: [String: String]?
        /// The ARN of the network load balancer of the VPC targeted by the VPC link. The network load balancer must be owned by the same Amazon Web Services account of the API owner.
        public let targetArns: [String]?

        @inlinable
        public init(description: String? = nil, id: String? = nil, name: String? = nil, status: VpcLinkStatus? = nil, statusMessage: String? = nil, tags: [String: String]? = nil, targetArns: [String]? = nil) {
            self.description = description
            self.id = id
            self.name = name
            self.status = status
            self.statusMessage = statusMessage
            self.tags = tags
            self.targetArns = targetArns
        }

        private enum CodingKeys: String, CodingKey {
            case description = "description"
            case id = "id"
            case name = "name"
            case status = "status"
            case statusMessage = "statusMessage"
            case tags = "tags"
            case targetArns = "targetArns"
        }
    }

    public struct VpcLinks: AWSDecodableShape {
        /// The current page of elements from this collection.
        public let items: [VpcLink]?
        /// The current pagination position in the paged result set.
        public let position: String?

        @inlinable
        public init(items: [VpcLink]? = nil, position: String? = nil) {
            self.items = items
            self.position = position
        }

        private enum CodingKeys: String, CodingKey {
            case items = "item"
            case position = "position"
        }
    }
}

// MARK: - Errors

/// Error enum for APIGateway
public struct APIGatewayErrorType: AWSErrorType {
    enum Code: String {
        case badRequestException = "BadRequestException"
        case conflictException = "ConflictException"
        case limitExceededException = "LimitExceededException"
        case notFoundException = "NotFoundException"
        case serviceUnavailableException = "ServiceUnavailableException"
        case tooManyRequestsException = "TooManyRequestsException"
        case unauthorizedException = "UnauthorizedException"
    }

    private let error: Code
    public let context: AWSErrorContext?

    /// initialize APIGateway
    public init?(errorCode: String, context: AWSErrorContext) {
        guard let error = Code(rawValue: errorCode) else { return nil }
        self.error = error
        self.context = context
    }

    internal init(_ error: Code) {
        self.error = error
        self.context = nil
    }

    /// return error code string
    public var errorCode: String { self.error.rawValue }

    /// The submitted request is not valid, for example, the input is incomplete or incorrect. See the accompanying error message for details.
    public static var badRequestException: Self { .init(.badRequestException) }
    /// The request configuration has conflicts. For details, see the accompanying error message.
    public static var conflictException: Self { .init(.conflictException) }
    /// The request exceeded the rate limit. Retry after the specified time period.
    public static var limitExceededException: Self { .init(.limitExceededException) }
    /// The requested resource is not found. Make sure that the request URI is correct.
    public static var notFoundException: Self { .init(.notFoundException) }
    /// The requested service is not available. For details see the accompanying error message. Retry after the specified time period.
    public static var serviceUnavailableException: Self { .init(.serviceUnavailableException) }
    /// The request has reached its throttling limit. Retry after the specified time period.
    public static var tooManyRequestsException: Self { .init(.tooManyRequestsException) }
    /// The request is denied because the caller has insufficient permissions.
    public static var unauthorizedException: Self { .init(.unauthorizedException) }
}

extension APIGatewayErrorType: AWSServiceErrorType {
    public static let errorCodeMap: [String: AWSErrorShape.Type] = [
        "LimitExceededException": APIGateway.LimitExceededException.self,
        "ServiceUnavailableException": APIGateway.ServiceUnavailableException.self,
        "TooManyRequestsException": APIGateway.TooManyRequestsException.self
    ]
}

extension APIGatewayErrorType: Equatable {
    public static func == (lhs: APIGatewayErrorType, rhs: APIGatewayErrorType) -> Bool {
        lhs.error == rhs.error
    }
}

extension APIGatewayErrorType: CustomStringConvertible {
    public var description: String {
        return "\(self.error.rawValue): \(self.message ?? "")"
    }
}
